A permanent link to an item (a blog post, an attachment, ...). The default structure is "?p=123", but WordPress can handle "pretty permalinks" and will rewrite them internally to the former version. If you have a question about special rewrite structures you should use the [url-rewriting] tag.

learn more… | top users | synonyms (1)

2
votes
2answers
5k views

Custom permalink structure for custom post type

I´m using the following code to create a new post type: /* Create custom post type: "Tilbud" */ register_post_type('tilbud', array( 'label' => __('Tilbud'), 'public' => true, 'show_ui' => ...
2
votes
2answers
4k views

How to modify URL structures in custom post types and taxonomies or terms

I am well aware that there are several posts covering the topic of customizing the permalink URL structure of custom post types, custom taxonomies, and taxonomy terms. However, none of them are real ...
2
votes
1answer
2k views

Move WordPress site from one domain to another

I've read through the codexs and I'm trying to find out the best way to change or move my MySQL and subdirectory files to a new domain without extraneous effort. For instance, I built a stage site ...
2
votes
3answers
5k views

Facebook Comment Count

I am a bit of an amateur when it comes to PHP and WordPress but I have rigged up the following code: function fb_comment_count($url = 'some url here') { $filecontent = ...
2
votes
2answers
751 views

Using underscores instead of hyphens in the permalink

What's the best way to ensure that post and page slugs use underscores instead of hyphens, without needing to edit the slug manually (or updating the page manually) Current permalink: ...
2
votes
5answers
3k views

WordPress permalinks Yahoo hosting(no .htaccess allowed)

I have moved a Wordpress install to a client from sub folder to the root folder. Right now, everything works fine, except for the friendly URLs. I currently have to set the Permalink feature in ...
2
votes
2answers
2k views

Custom taxonomy listing page when no term set (all terms)

I've created a custom taxonomy "foo" with rewrite slug "foo" and query_var "foo". Say for example, I also have terms "bar" and "baz" in the "foo" taxonomy. At the moment, permalinks like /foo/bar ...
2
votes
2answers
3k views

Create slugs programmatically

I'm updating programmatically posts in a WP 3.01 install, using custom made tools. Sometimes I do change programmatically post_status from DRAFT to PUBLISHED using custom SELECT queries, however this ...
2
votes
2answers
357 views

Determine WP_Query parameters from URL

I'm wondering if it's possible to determine WP_Query parameters by only using the given page URL. The reason I'm trying to do this because I'm developing a SPA theme (and ultimately a JSON response) ...
2
votes
2answers
429 views

Different permalink for posts and authors

I tried to avoid ask this question, because I think that must be simple, but after long hours trying to get an answer I cant achieve it. I am trying to get a permalink structure like this: ...
2
votes
2answers
2k views

Post ID At The End Of Permalink URL Effects Performance (Positively)?

HARD NOTE: This question is solely about performance, and NOT search engine optimization. So, please make sure your answers are as such. W.r.t permalinks, "year" is the most obvious numeric of ...
2
votes
1answer
4k views

Why is “/page/2/” not working?

Finally got pagination to work with the below code, but now the pagination links to /videos/page/2/, which doesn't exist. How do I get page 2 to work? <?php $temp = $wp_query; $wp_query= null; ...
2
votes
3answers
367 views

Must permalinks always point to single post pages?

Suppose that I have a blog with few posts per month, and no comments, and I don't want to show posts in single post pages, but always "in context" (say, together with the posts in its month - or ...
2
votes
2answers
2k views

Why does a custom post type need the ''hierarchical' args setting?

I'm struggling with understanding some things about CPTs and and could do with some help. I can see that taxonomies often need to be hierarchical, but can't see how/when a custom post type would be? ...
2
votes
1answer
135 views

Creating a path in a plugin to call a function

Okay, let's assume that I want to create a dynamic "printable" page using a system that doesn't play well with wordpress's theming engine, is there a way for me to define a "permalink" in my plugin ...
2
votes
1answer
744 views

Using %postname% tag with a Custom Permastruct creates 400 Bad Request Errors from the server

This is related to another question that I had asked earlier. I'm doing some rewrite code to create some custom permalinks for a custom post type. I think I'm getting it mostly working except I'm ...
2
votes
1answer
4k views

Permalink rewrite 404 conflict- WordPress Taxonomies/ CPT

Wondering if someone could tell me why sub pages (child pages) no longer work (eg: www.mysite.com/type/childpage). I have a page called "Type" (working fine), and I wish to have Child Pages of "Type" ...
2
votes
1answer
690 views

Custom Post Type: Get most recent permalink

Stupid question, I bet: I'm doing a website for an artist where I have a custom post type of "Painting". How do I get the permalink of the one added most recently?
2
votes
2answers
611 views

Using WP rather than .htaccess to redirect pages/posts

I run a site with over 100 specific redirects in the htaccess for legacy html files that were subsequently brought into WP. There are also rules for pages within a date range to redirect to the home ...
2
votes
2answers
74 views

Where is the old post permalink slug stored?

I published an article with permalink slug: http://domain.com/writing Then after publishing, I changed the permalink slug to writing-lorem. Now, whenever I visit /writing, it redirects to ...
2
votes
1answer
75 views

Permalinks, Rewrites, Get Variables, Oh My!

Ok, so I know it's a silly title, but it's exactly how I feel right now.. I've created some custom rewrites for WordPress and they work great, the only problem is that now I need to add pagination. ...
2
votes
2answers
1k views

Resolve a custom post type name vs. page permalink conflict (same slug)

I have a custom post type called "visningshus", and also a Page with that slug. This is as it should (must) be. Currently, "http://my-site.com/visningshus" lists all posts of that type. I want to ...
2
votes
4answers
1k views

Why would Numeric permalinks work, but %postname% won't?

[Question edited as I discovered more] I have a weird problem, in that my permalinks do not work. Well actually, it works when the permalink-structure is set to something which begins with static ...
2
votes
1answer
816 views

How to increase the character limit for post name of 200?

I have post name in Thai which uses UTF-8 character. Many of them encode into super long in ASCII e.g. วิธีการหลีกเลี่ยงข้อผิดพลาดทั้ง-8-ในชีวิตการแต่งงาน I've changed the type of "post_name" using ...
2
votes
1answer
289 views

Change link to other post to shortlink in the editor

Curently if we use the insert link dialog to insert a link to another post, WordPress always use the permalink of that post. The problem is when we change permalink structure, that link will be ...
2
votes
2answers
581 views

Mass Permalink Changer

I recently converted a site from Moveable Type to WordPress and noticed that the permalinks for each post are short, cut off and have underscores in them. What I am looking to do is if there is a ...
2
votes
2answers
342 views

Random post permalink

I want to make a random permalink for each new post. For example when an author creates a new post, he gets this kind of permalink automatically: http://mysite.com/x5Kvy6 (like bit.ly). But I want to ...
2
votes
3answers
693 views

Custom Taxonomy in Permalink of Post

It is possible to use this as a permalink for a post: /%category%/%postname%/ But lets say I've created a taxonomy called "artist". I'd like to use this for my posts: /%artist%/%postname%/ I ...
2
votes
1answer
227 views

How to prefix post permalinks with /blog/ - without affecting custom post types?

I have several custom post types, which are properly structured as /%post_type%/%postname%/, however I wish to have the same effect for regular blog entries: /blog/%postname%/ If I prepend the ...
2
votes
3answers
657 views

flexible rewrite 'ramble' URLs with Wordpress

I want to access my post with id 17 like this: http://localhost/archives/17/moot-bla-foo-ramble In other words, the id shall decide, everything thereafter may (or may not) be the slug or anything ...
2
votes
2answers
9k views

WooCommerce permalinks [closed]

I got the following question: When I go to a WooCommerce category, the link displays like this: http://www.example.com/product-category/category/ Where the bold text is the link like it is and the ...
2
votes
1answer
69 views

What Defines What Category A Post Picks (if in multiple)

If I have a post in multiple categories, what defines what category shows up in the URL? Assuming I have permalinks setup as /%category%/%postname% is it the ID or the name?
2
votes
2answers
31 views

Migrating Wordpress blog to New Webhosts, something is adding a # and gibberish

I just migrated a WordPress blog from one host provider to another. Did a clean install on the new server, and everything seems to be working fine except all the permalinks for some reason add a ...
2
votes
2answers
761 views

Get Permalink of Network Blog Post

I am trying to write a function that will allow me to specify a post ID and a blog ID, and then have it return the permalink and title of the blog post. I need this to be efficient because the ...
2
votes
1answer
761 views

Nice RSS Feed URLs for each custom post type

By default WP seems to display all posts of all types in the main RSS feed. You have to add a post_type query variable to show post of a certain type... So how can I turn this: ...
2
votes
2answers
666 views

How to change “permalink” structure in “Wordpress Thesis” theme?

I have installed Thesis theme. The default permalink structure is BLOGURL/%postid%/ When I change it to BLOGURL/%postname%/, I can't access the pages. I have modified .htaccess file and the "nav_bar ...
2
votes
4answers
2k views

Remove Custom Taxonomy Base

I am using custom taxonomies with WordPress 3.0.4 I am wondering if anyone knows how to remove the taxonomy base from the URL? I have seen plugins that do it for categories and tags, but not for ...
2
votes
2answers
1k views

Search result permalink

how to make permalink available for search result page /?s=one+two+ok to /search/one-two-ok/ thank
2
votes
1answer
186 views

Apostrophe in permalink results in page not found

I'm working through a migration from Drupal to a WP multisite network, I've got a post meta field that contains the URL of the old post (mostly to maintain social counts and such) that I'm using for ...
2
votes
1answer
104 views

Permalink Settings: optional settings doesn’t apply to editor

In my WordPress 3.8 in my "Permalink Settings" I've chosen the option "Post name". Then I've added "Optional" for "Category" ( %category%/%postname% ), the URLs works like I wanted - ...
2
votes
1answer
404 views

Permalink redirection from 'Day and name' to 'Post name'

In my blog, I used the Day and name permalink structure for many days. Recently I came to know the SEO tips and made the permalink structure to Post name. So I migrated from: ...
2
votes
1answer
208 views

Some posts returning 404 instead of displaying post

I'm having a problem with my Wordpress install. All of a sudden some of my posts return 404 errors when I try to go to their permalink. My post names are all numbers and this started happening when my ...
2
votes
1answer
130 views

How to assign a Permalink to a Function

In Drupal, you can assign a URI to a function that gets called, like this: function mymodule_menu() { return array( 'custom_uri' => array( 'page callback' => ...
2
votes
1answer
2k views

Setting 404 page in Nginx

I am using this page (http://wiki.nginx.org/WordPress) to setup my WordPress on a nginx/php-fpm server. Everything is okay, except the 404 page When I request www.example.com/foo, it send me the ...
2
votes
1answer
641 views

How to achieve this permalink -> category-name/custom-post-type-name/post-name

I am trying to use categories to provide the structure for my site. I will create sections on my site called England, Wales, Scotland and Ireland . These will be categories. My posts will use custom ...
2
votes
1answer
187 views

custom post type permalinks with category and tags

I have a custom post type called 'designs' and have registered taxonomy 'design_category' and 'design_tag'. I'm trying to get the permalinks as follows but not having much luck - seems having 2 ...
2
votes
1answer
121 views

Custom Post Type “Event” with custom permalink structure

I need some help about Custom permalinks for custom post types. I have created a custom post type called "evento" and 3 custom fields for storing date, month and year of the events. I would like to ...
2
votes
1answer
89 views

How to get wordpress link to fully evaluate when coming from facebook

The short version: Any link from Facebook to a page stops evaluating at the "hardcoded page" in the wordpress press install, ignoring the remaining parts of the URL. It doesn't allow the shortcode ...
2
votes
1answer
1k views

Permalink rewrite with custom post type and custom taxonomy

I think thats a quick one: I've got: Custom post type: Food Custom taxonomy (Registered to Food): Fruits Terms in Fruits: Apple, Orange, Cherry If I type in example.com/food?fruits=Apple,Cherry, ...
2
votes
2answers
2k views

Custom permalink structure only for default posts

Does anybody know how to modify the url struct only for the single post page? When I go to a post page, the url should look like: example.com/xxx/my-post. All other urls (with the exception of the ...