Build Your Own Business Website header image

Community Library Website – Part 22, Create the Permalink Structure

Difficulty Level -

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.

This is the twenty second in a series of live lessons on using WordPress and Thesis as a Content Management System (CMS). In this lesson we change the permalink structure from the tradition style to a custom structure which allows for semantic URLs (they can be easily read and understood). We make this change because it makes for a better URL structure from the standpoint of SEO. And we install and activate the Custom Post Permalinks plugin to resolve a problem the URL structure is having with the custom post types.

A note about Permalink structure in WordPress 3.3. It is no longer necessary to include a number in your permalink structure if you are starting a new website with WordPress 3.3.

Community Library Website – Case Study Part 1 – Site Organization
Community Library Website – Case Study Part 2 – Create Custom Post Types
Community Library Website – Case Study Part 3 – Custom Post Type Configuration
Community Library Website – Case Study Part 4 – Custom Taxonomy Decisions – Theory
Community Library Website – Case Study Part 5 – Custom Taxonomy Decisions – Practical Application
Community Library Website – Case Study Part 6 – Incorporating Existing Data Into the Project
Community Library Website – Case Study Part 7 – Creating Hierarchical Custom Taxonomies
Community Library Website – Case Study Part 8 – Creating Non-Hierarchical Custom Taxonomies
Community Library Website – Case Study Part 9 – Creating Custom Post Meta
Community Library Website Case Study – Part 10a – Restore the Database Using BackupBuddy
Community Library Website Case Study- Part 10 – Creating Custom Post Meta – Continued
Community Library Website – Part 11 – Importing Existing Data to the Website
Community Library Website – Part 12 – Prepare Existing Data for import by the CSV Importer plugin
Community Library Website – Part 13 – Import Existing Data Using the CSV Importer Plugin
Community Library Website – Case Study Part 14 – Date in Permalink Configuration
Community Library Website – Part 15 – Importing Images
Community Library Website – Part 16b – Final Data Import
Community Library Website – Part 17 – Add Thesis Post Meta to Custom Post Type
Community Library Website – Part 18 – Add WordPress 3.0 Menus
Community Library Website – Part 19 – Add Post Meta and Taxonomy Information to the Post Display
Community Library – Part 20 – Add topics and audience to book display
Community Library – Part 21 – Display the Rest of the Post Meta in the Post
Community Library Website – Part 22, Create the Permalink Structure
Community Library – Part 23 – Remove Custom Post Meta from Post Display
Community Library Website – Part 24, Add Taxonomy and Post Meta Data to the Teaser
Community Library Website – Part 25, Add Taxonomy Data to the Teaser
Community Library Website – Part 26, Adjust the Teaser Styling Using Design Options
Community Library Website – Part 27, Styling the Teaser Using CSS
Community Library Website – Part 28 – Fine Tune the Teaser Display
Community Library Website – Part 29, Designing a Custom Catalog Page
Community Library Website – Part 30, Using a Query String in a URL
Community Library Website – Part 31, Adding Custom WordPress Menus
Community Library Website – Part 32, Add Custom Menus to the Catalog Page
Community Library Website – Part 33, Add Another Custom Menu to the Catalog Page
Community Library Website – Part 34, Troubleshooting Custom Menus
Community Library Website – Part 35, Add Styling to WordPress Menus
Community Library Website – Part 36, Add HTML Markup to WordPress Menus
Community Library Website – Part 37, Add WordPress Menus to Archive Pages
Community Library Website – Part 38, Add and Style a List of Tags
Community Library Website – Part 39, Add a Search Box to the Sidebar
Community Library Website – Part 40, Add Links to the Sidebar
Community Library Website – Part 41, Add Taxonomy Drill Down Browsing
Community Library Website – Part 42, Custom Loop to Display Custom Post Types
Community Library Website – Part 43, Simple Custom Query
Community Library Website – Part 44, Custom Taxonomy Query
Community Library Website – Part 45, Add Thesis HTML Structure to Teasers
Community Library Website – Part 46, Display Posts from the Last 60 Days
Community Library Website – Part 47, Custom Loop If Have Posts
Community Library Case Study – Part 48, Increase the Number of Posts that Display on the Custom Catalog
Community Library Website – Part 49 – Naming Conflicts in Custom Taxonomies
Community Library Website – Part 50 – Find and Replace Semi-colons in the Database
Community Library Website – Part 51 – Modify Taxonomy Names Directly in the Database
Community Library Website – Part 52 – Sort Posts by Meta Value
Community Library Website – Part 53 – Show the Term Label Only when a Term Exists
Community Library Website – Part 54 – Sort Archive Posts by Meta Value
Community Library Website – Part 55 – Add Sort Order to Custom Taxonomy

Video Transcript

Rick: So shoot, I forgot what number we’re on. Anyway, we’re going to talk about the permalinks now for our Community Library Website project and if you go to the site at the moment, you can see there has a very traditional type of permalink structure. That is, it has the query question mark and then it has… the question is what kind of media type is it? And the answer is book. And if we select a book, the question is which catalog item is it? And the answer is 131 Christians Every One Should Know.

And so, that is actually crummy SEO from a… or crummy URLs from an SEO standpoint, right? You want nice semantic URLs that can be easily read and understood. And it’s even worse really… say, if we go to our blog post you know, here’s our first blog post. Community Library Case Study and the question is what do you want to read? And the answer is p=175 which means absolutely nothing, right?

And so, this is what we’re going to fix. Actually, when we’re done fixing this, this is the other thing we’re going to fix. You can see that we have listed our topics, audience, all this kind of stuff attached to our regular post which of course, we don’t want.

Okay so anyway, let’s go back to our dashboard and the first thing to do here is to just go to our permalinks settings and set up our standard permalinks. Now, if you’ve been paying much attention to me for the last several months, you know that this is my recommended standard permalink structure. So I select month and name first and then from there, I select custom structure. Take month num out of this and paste it over year. So we start with the month number and then we type in category here and then leave post name. And then what this will do is it places a date number at the beginning which is necessary in order for WordPress to be able to process this stuff well. So we put month number at the beginning then we put our category in the middle and then our post name last. We hit save changes and we go back over to our site.

Now you can see the URL is 04 uncategorized… I mean, obviously, we should add a category for this and then the Community Library Website. This is very similar to what happens on my site, right? Here’s byobwebsite and then video tutorials and then customize thesis like a pro. If we come down here to the 1st lesson, we’ve got Video Tutorials, Customize Thesis Like a Pro, Manage the File Structure. And then if we look at the 1st video, now we get to the month number, Video Tutorials, Customize Thesis Like a Pro, Managing the File Structure, the default WordPress and Thesis structure.

So this is a semantic URL and that’s what you’ve got going on here. And that’s what will happen…I mean, it’s exactly the same setting that produces this URL. Okay but if we look at our catalog, we still end up with question post type = catalog items and if we go to books, we still end up with… well actually, that’s not too bad. Oh actually, we even get failure there. Look at that. We even get failure in our… I didn’t think that would happen but you can see that when we select our library items here, it fails because these URLs don’t actually resolve properly or this URL structure doesn’t actually resolve properly to our custom post types. So it’s even worse than I thought.

Okay but anyway, we go to our dashboard. We’re going to use a plugin to do this and the plugin is going to be Custom Permalinks, I believe is the name of it. So let’s go down to plugins and we hit Add New. We’re going to install Custom Permalinks… yeah, Custom Post Permalinks. That’s what it is and this is the same plugin that we installed on the Community News Website. Okay yeah, we’re going to install this plugin. We’re going to activate the plugin and then we’ll come back down here to permalinks and we’ll employ it.

Now, what I want to accomplish here is I want the name of the website and then I want it to say for our custom post type catalog items, I want it to say catalog items and then the media type and then the name of the catalog item. So what we’re going to do then is we’re going to come down here and we’re going to make it say that in this section here. And the first thing we’re going to do is capture month num. Let’s see, we’re going to put that right here. So we get our month num in first and then we are going to use a post type which is what’s going to say catalog items for us. So we’ll grab post type and we’ll put that in there. It’s just month num and post type so it’s going to say 04 catalog items and now what we want is the media type. And what this says is that you can use any of the… let’s see, where did it say that? Okay for example, if you have a taxonomy called foo_bar, the tag would be foo_bar like that. So you can add a tag for any taxonomy registered for the post type.

And so, media type is the tag that we have registered for this so we’ll say %media-type. Now it’s again absolutely essential that you use exactly the same thing as you did when you created this taxonomy. So before we save this, if we come down to custom post types and look at manage taxonomies, you can see under media type, that’s what we called it, media-type. So that’s what it has to be called here, media-type. So you got month num, post type which is going to say catalog items, media type which will say book, DVD, audio book, something else. You have catalog items which is the name of this post type.

Ultimately, if we do book reviews, it will be the same kind of thing. This review here is the name of the review or the title of the review. This catalog items is the title of the catalog item so okay, let’s go ahead and save that. And then let’s go back to our site, let’s go to our catalogs for books. Now it says media type book. If we go to one of our books, now it says 01 for the month number, catalog items book, 131 Christians Every One Should Know. If we go to the adult audience, it’ll say audience adult and if we pick a different book, there’s the month number, catalog items book, Jesus In His Own Words.

If we instead look at DVDs, Madame Blueberry, this is catalog items DVD Madame Blueberry.

So Pam, I’m going to unmute your microphone here. Do you like the way this URL structure works?

Pam: Yes, I like this very much. Thanks, that’s very helpful to learn about that plugin.

Rick: Yeah, you know, especially for SEO, it’s really, I think, important to be able to have this kind of thing. In the first place, somebody searching for the Madame Blueberry DVD might find this page because of this URL. So okay, well that wraps up the URL part of it. It’s actually a lot easier than I was really expecting it to be.

0 Comments… add one

Save $200 on Membership Now!

Start learning today for as little as
$0.82 PER DAY!
THIS IS A LIMITED TIME OFFER!
Subscription Options
0 comments… add one

Leave a Comment