Build Your Own Business Website header image

How to Display Testimonials in Thesis 2.1 Using Custom Post Types & Taxonomies – Part 7 – Setup Related Testimonials

Difficulty Level -

Filed Under Topics - ,

Applies to -

Whoops, you've found some premium content!

Watch the opening clip of this video to preview it,
the full video is available to paid members.

You’ve seen how to display a list of testimonials on a page using the Thesis 2.1 Query Box and now we’re going to look at displaying related testimonials.

Let’s find a seminar that is related to one of our testimonials here. Let’s use the Thesis 2 Technical Review seminar. Let’s say that the only people who are going to look at this are going to be web designers.

Change Testimonial Type on a Page

I think we’re going to have to go Pages. Okay, so here we are in this page, Free Video Tutorials. Here’s a page that should be displayed to business owners but not to everybody else. So let’s edit this page and come down here to the Testimonial Types and choose Business Owner as the testimonial type. Update it.

Use BYOB Related Post Query Box to Choose Relatedness

Then we can use another box of mine, which is called the BYOB Related Post Query Box. And with the BYOB Related Post Query Box, what we can do is choose that dimension of relatedness. So, come back over here to Thesis, and Boxes, and Manage Boxes. Then upload a box, choose the file, add the box. Click ok. Activate it. I’m going to refresh the page template here for a second.

Go to the Content Area, and now what we’ll do is take out of the sidebar the Testimonial Typical Query Box and we’re going to include a BYOB Related Post Query Box. We’re going to say Testimonials – Related Post Query Box. The Post Type is going to be Testimonials. The Select Relationship Taxonomy and we only have one kind of taxonomy so we’ll choose Testimonial Types.

I think we’re good to go there, we’ll say okay to that. Shift+drag and drop it into the Main Sidebar. Now we’ve got a Headline, an Excerpt. Our Headline is going to be H4, we’ll link it to the article. The Excerpt is fine.

I think one other thing I want to do to this is add a title to it. This is one other thing this query box adds, is the title options. So now we can give the query box a title. We can say Testimonials from other and then note what you can do here is if you enter %s, that will place the taxonomy term name in there.

We called this Taxonomy Business Owner, so what we’re going to say is Testimonials from other %ss. So Testimonials from other Business Owners is what’s going to come out of this. And let’s make it an H3. Okay, say ok to that. Save the template.

Now if we view this page, we now have something that says Testimonials from other Business Owners, and the only testimonial that’s showing up is Sammy’s testimonial. If we edit this page and instead of Business Owners, we put Web Designer and update it and view the page, now this is Testimonials from other Web Designers. And now it’s entirely different, it’s the other testimonial.

So this is the way that you can set up a set of related testimonials. All you have to do is make sure that the taxonomy, which in this case was testimonial type, is shared by both the testimonials and whatever post types you want to be able to set this choice for.

I only set it to pages which is why we had to fuss around trying to find a page to add this to but you can do it to anything. If the page has nothing assigned to it at all, as if the page does not have any testimonial assigned to it, then what’s going to happen is no testimonials will show up there. Because this box only shows testimonials that are related. So it doesn’t even put this title up there, it just shows empty.

0 Comments… add one
0 comments… add one

Leave a Comment