Articles of slug

Custom walker with hashes instead of links (one-page layout)

I am currently developing a one-page based layout with WordPress where the actual content is split up into separate pages in the backend, which are all knit together to a one-page layout in my front-page template file. The WordPress menus allow for custom URLs which is probably the easiest way to cater a one-pager by […]

Auto-create a pretty permalink for a bunch of posts

I have spammed many duplicate posts from one initial and now after editing them the url structure for them is something like where base-name is the slug of the duplicated initial post. Now, I could change the permalink for every one of them manually I know, but is there a way to create a […]

Categories vs. Page Site Organization

I need to organize the pages on my website so that they appear with the proper hierarchy. The problem is that the category-derived page is appearing outside my hierarchy. This is the current hierarchy if you are on my site today: Home -> Internal (page) -> Docs (page) -> Policy (category) […]

Function to list all post slugs for every post in my WP database?

Function to list all post slugs for every post in wp_posts table? I assume there’s an official function to generate a post slug, but maybe someone here already has the answer.

Slug is redirecting to 404

I had a page called Recipes. I changed it to Recipes_old and changed the slug so I could create a new Recipes page. When I created the new Recipes page the slug was properly defined as /recipes/ but I can’t get to the page, WordPress is redirecting all requests to /recipes_old/ How do I remove […]

How to get slug of current category in taxonomy template?

How can I retrieve slug of current taxonomy being viewed in taxonomy template? I tried to codex but found nothing on taxonomy template page. To further explain, lets say I am viewing category flowers so how can I retrieve slug of category flowers?

How do I fix permalinks for custom post types that has the same slug as a page?

I know that it’s impossible to have the same custom post type slug as a page. So, I thought it might be resolved in this way: ‘rewrite’ => array(‘slug’ => ‘my-category/!#’) for register_post_type But I get “Page not found” every time I visit /my-category/!#/title-1 As you understand, I also have a page named “/my-category”. Is […]

Easiest way to simulate WordPress's URL resolution to retrieve post ID, etc?

I’m curious if it is possible, in a plugin/custom code, to take an URL that has been generated by the currently running WordPress site & parse it to retrieve the $blog_id and $post_id? ie. taking a string like “” and determining that this is post #6 (“whatever”) on blog #2 (“myblog”). I realize that I […]

Get the name an the description of a link category

I have a link category with the id $id=23; and the slug $slug=friends;. I managed to read all links from that category using get_bookmarks($id). Now I also want to use the name and the description ob the link category. How geht I get these values? I tried for example: $cat = get_the_category($id); $output .= “<p>Description: […]

Using a portfolio_category slug in wordpress URL

I won’t lie – I don’t know php but I enjoy digging around trying to find ways to customize themes so that they behave how I want them to. Any help would be very much appreciated. What I am trying to do: There is a section in a wordpress theme I am using which allows […]