Questions tagged [permalinks]

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.

Filter by
Sorted by
Tagged with
1 vote
0 answers
6 views

After moving content to a new site, gallery thumbnails are not pointing to media files

I am moving content from an old site based on Wordpress 4.9 to a new website based on the current release and PHP 8. I have moved all the content - meaning posts, pages, media, and so forth - using ...
Ondrej's user avatar
  • 111
0 votes
0 answers
7 views

Unforeseen /? in the domain produces links with the same canonical tag

I've changed my robots.txt file as per below: User-agent: * Disallow: /wp-content/uploads/wpo-plugins-tables-list.json Disallow: /?s Sitemap: https://astro-geo-gis.com/sitemap.xml but it looks like ...
Geographos's user avatar
0 votes
0 answers
10 views

Using Custom Taxonomy in Default Post Slug

Hoping for some help... This relates to similar questions but with some variation where I haven't been able to get to a working solution. What I'm trying to do I want to use my created custom ...
Danny C's user avatar
0 votes
1 answer
12 views

how to ensure url uses post_name and not query post id?

the situation : my settings > permalinks are sets on post name, but sometimes anyway a post url is using the query post id : https://my_website.com/?p=4348 instead of https://my_website.com/my_post ...
hugogogo's user avatar
  • 111
0 votes
1 answer
11 views

Modify Post URL Programmatically

I am creating post using wp_insert_post(). I would like to insert Post URL at that time. How can I do that ?
Foysal's user avatar
  • 449
0 votes
0 answers
18 views

When accessing all pages except the homepage I get Nothing Found

I try to identify the reason why when visiting any page I get the message Nothing Found Ready to publish your first post? <a href="http://site.local/wp-admin/post-new.php">Get started ...
user615274's user avatar
0 votes
1 answer
12 views

Changing permalink won't redirect to new version of page

I created a new version of a Page. I changed the permalink of the previous (deprecated) version. I then changed the permalink of the new version to the original permalink. Unfortunately, Wordpress ...
jchwebdev's user avatar
  • 765
0 votes
0 answers
6 views

How to get the proper category in permalink with custom post type assigned to multiple categories

I was wondering if you could help me with the following issue. I have read a lot of cases, but couldn't trace anywhere good answer which explain, how this works. I created a custom post type: project ...
Brango's user avatar
  • 1
1 vote
0 answers
6 views

Help Needed: Issue with Change Permalink on DirectoryPress Listing Pages

I'm encountering a problem with a WordPress plugin I'm developing for DirectoryPress listing pages. The plugin aims to replace the default permalink with a new link specified by users in a custom ...
Xplosio's user avatar
  • 11
0 votes
0 answers
14 views

Custom permalink structure for posts in specific category not working

I'm seeking assistance with a custom permalink issue I'm facing on my WordPress website. I've been trying to implement custom permalinks for posts belonging to specific categories, namely "...
mtr's user avatar
  • 1
0 votes
1 answer
21 views

Not able to change Wordpress Permalink Settings

I am planning to start a new website using WordPress. I don't have any technical knowledge. After the theme installation on my website, I am not able to change the Permalink Settings. By default it is ...
Pradeep N's user avatar
0 votes
0 answers
9 views

My posts images and links are not correct when I publish my home page

For my "https://eclipseglassesreview.com/" website: when I am in Elementor editing my home page, the posts images and links are correct. When I publish the home page, the posts images ...
Leroy's user avatar
  • 1
1 vote
1 answer
12 views

How does WordPress manage to differentiate between post and page URLs without a distinct base, and how can I replicate this functionality?

I want clean URLs without a custom taxonomy name or custom post name. The project and its structure are somewhat complex. The customer wants certain strings from a third party plugin to be removed ...
Rick Pestel's user avatar
0 votes
1 answer
12 views

changing the default structure of category & tag permalinks

I would like to remove the "category" part of my catergory permalinks structures. I know you can replace this base by using another word, but I want no words. So, now I have website.com/...
Amber's user avatar
  • 1
0 votes
0 answers
19 views

Creating Wordpress pages with post name as slug

I have an issue on a domain with a freshly installed Wordpress. I try to change my permalink structure to be Post Name so that when I create a page with the name "Test" I should be able to ...
eligolf's user avatar
  • 123
0 votes
1 answer
36 views

I want to change my permalink structure

I am looking to update my permalink structure by adding a category and date in the UR to make it more feasible for users to understand the post category and published date. Can you please guide me on ...
Stumble Guys's user avatar
0 votes
1 answer
8 views

Permalink issue with new blog posts > getting 301 redirect

My permalink structure is: https://website.com/sample-post/ However, each new blog post is getting a 301 redirect from a link like this: https://website.com/2024/01/30/ I see that each new blog post ...
Meek Mill's user avatar
1 vote
0 answers
41 views

Custom permalink for post of one category

I want to customize the permalinks structure for posts in WordPress based on their categories but only posts of one category, The permalinks of the "android" posts category become like these:...
Heisenberg's user avatar
0 votes
1 answer
42 views

Understanding images handeling

I am facing an understanding issue with image accessibility on my WordPress website. Here’s the scenario: My website URL is mysite.com. I have a post titled “hello-world,” which is accessible at ...
kocjs's user avatar
  • 23
0 votes
2 answers
36 views

All WP pages direct to 404 or index.php

I made a basic site based off the underscores (_s) theme with a CPT/taxonomy, Advanced Custom Fields plugin, and 3 page templates. A simple site. Nothing out of the ordinary. For some strange reason, ...
user239138's user avatar
0 votes
1 answer
21 views

How to handle custom taxonomy archive when no posts will have that taxonomy

I have a hobby site where I record the changing tenants of a big shopping centre. For each tenant I create a post and use a ACF repeater to store the unit they are in and open/close dates. The unit ...
Damien Carbery's user avatar
0 votes
0 answers
19 views

Adding Category to Child Posts Permalink

I'm attempting to add a category of each child post to that post's permalink. The post type is called lessons. I have a taxonomy called Child Categories that contains the terms workbooks and workbook-...
Felicia Santos's user avatar
1 vote
1 answer
33 views

How do I disable the changing of the permalink for published posts (for non-admin)?

I want to make it so that, when a post's (not page) status is published, non-admins will not be able to change the URL (using the interface shown in the image). Maybe it's greyed out or just not ...
user18102663's user avatar
0 votes
0 answers
5 views

I have two different parent menus in my main menu. the first parent menu with a dropdown is called "services" and the second dropdown is called

I have two different parent menus in my main menu. The first parent menu with a dropdown is called "service" and the second parent menu with a dropdown is called "portfolio". All ...
George g's user avatar
0 votes
1 answer
71 views

Execute wp_after_insert_post after the permalink is customized

I'm trying to set a meta property to a new post's permalink using update_post_meta. When I run this on wp_after_insert_post I get a permalink that ends in "?p=[ID]". If I update the post to ...
Tim Troiano's user avatar
0 votes
1 answer
146 views

How to remove parent slugs from child pages permalinks?

I remove them all right, but when I actually try to go to a page, there is a 404 error. The code I have used ( variation of Removing Parent Page(s) from Permalink ) function my_pages_permalink( $link, ...
BonMoDo's user avatar
  • 11
0 votes
0 answers
61 views

Cannot use dynamic prefix for WooCommerce permalink

I need to use a dynamic permalink structure for WooCommerce products, basically, the structure I'm trying to achieve is the following: /<dynamic>/post_name. So what I did is create a rewrite tag:...
sfarzoso's user avatar
0 votes
1 answer
48 views

How to add .html extension only to pages without child pages?

I have something like this: Page 1 Child page 1 Child page 2 Page 2 Child page 3 Child page 4 Grand child page 1 Grand child page 2 Page 3 Now I need to make only Child pages 1-3 + Grand child ...
BonMoDo's user avatar
  • 11
0 votes
0 answers
45 views

Permalinks and redirects

I would like to change the permalink from /%category%/%postname%/ to /%category%/%postname%-%post_id%/ How to set up a redirect correctly?
W1ns's user avatar
  • 1
0 votes
0 answers
19 views

Remove slug of multiple custom post types with and without hierarchical

I have two custom post types called toplijst and product. I am trying to achieve the following permalink structure: Toplijst: website.com/toplijst/parent-toplijst/ website.com/toplijst/parent-toplijst/...
sem roijackers's user avatar
0 votes
1 answer
45 views

why same category base and single post base don't work?

I have checked a similar question on the site but there was no satisfactory answer? Here is what I would like to accomplish. When I set the permalink structure to '/blog/%postname%/' this gives me the ...
yucelm's user avatar
  • 3
0 votes
3 answers
90 views

Modify the permalink structure for a specific category

I searched for many solutions before opening this post, but none worked correctly. This is a complicated matter because it can significantly impact the site if not done correctly. I need to have a ...
Jader's user avatar
  • 1
1 vote
1 answer
40 views

Change the slug of post type using custom code

How can the default post post type permalink slug be modified to add /blog? Without changing other post types
Hambs's user avatar
  • 11
0 votes
1 answer
65 views

Yoast SEO canonical URL gets pointed to the homepage

I noticed in Google Search Console that pages are increasingly getting removed from the index due to their canonical. For some reason — it points to the home page for some articles. After some digging,...
dodov's user avatar
  • 197
1 vote
1 answer
15 views

How do we ReWrite HTACCESS to point a cat/subcat Product URL, to Cat/ only?

We have a problem where a site has got some odd URLs indexed by Google. This is the incorrect path: example.com/shop/mens/jeans/jean-product/ This is the correct path: example.com/shop/mens/jean-...
Simon_a6's user avatar
2 votes
0 answers
35 views

@wordpress/env cli doesn't seem to properly update permalink structure until visiting the WP Admin Permalink settings page

I'm using https://www.npmjs.com/package/@wordpress/env to set up a local docker-based WordPress development environment, which has been working great so far. I'm trying to build a script using ...
jv-dev's user avatar
  • 121
0 votes
0 answers
40 views

Cannot create custom post types with a specific name

I am creating custom post types using this code function create_custom_post_type() { register_post_type('courses', array( 'labels' => array( 'name' => __('...
Waleed's user avatar
  • 1
0 votes
0 answers
16 views

Custom templates based custom url structure in wordpress

I'm working on a website that includes a section for Barbers, and I want to achieve the following URL structure: Barbers {domain.com/barbers This page will have 2 section, 1 section will list Barber ...
Tarun's user avatar
  • 1
2 votes
1 answer
31 views

How do I get the URL section to show use a different domain in the WordPress Admin?

I am currently using a headless WordPress with NextJS and making adjustments in custom plugin index.php file. Within the admin, I am trying to create a better user experience for our content writers ...
Tim Tran's user avatar
-1 votes
1 answer
89 views

button onclick with get_post_permalink

I developed a custom post type. On my archive page for each post there is a <button>. The problem is that I can't put the link to the post in question. My button is in my loop. <button type=&...
Thica's user avatar
  • 17
0 votes
3 answers
135 views

Custom Post Types, Single Posts returning 404 Errors - flushing permalinks does not correct

I have a website that, using ACF Pro, I have created several Custom Post Types (CPTs) for. All using ACF Pro. Of them, 6 of the CPTs are showing fine with the archive and single templates. They are: ...
Mitch S's user avatar
  • 27
0 votes
0 answers
68 views

WP Category Archive /page/2+ pagination issue 404

Encountered an issue when navigating to archive pages within a category after page 1 of the results via pagination. This is the standard WP categories and not a custom query. Working: /category/...
ejay's user avatar
  • 1
0 votes
0 answers
27 views

No route was found that is identical to the URL and request method

I am getting the following error message in some plugins after a website move "No route was found that is identical to the URL and request method." I have already renewed the permal link ...
Chris's user avatar
  • 1
0 votes
1 answer
23 views

Category url; have it only answer to 1 category

I have a permalink custom structure that looks like this /blog/%category%/%postname%/ Thing is, that would make that if a post has category-1 and category-2 assigned, both /blog/category-1/post/ and /...
Fredy31's user avatar
  • 858
0 votes
0 answers
31 views

Custom post permalinks for specific categories

I have specific categories posts where i want to remove category name from URL. My current post link is: https://example.com/my_cat_name/post_name/ I want: https://example.com/post_name/ But only for ...
DevLoper's user avatar
1 vote
1 answer
29 views

changed permalink structure and now ajax functions are broken

I changed the permalinks from /%category%/%postname%/ to just /%postname%/ and now my custom ajax function returns a 500 error. The exact message I get in the console is: Failed to load resource: the ...
jon's user avatar
  • 11
0 votes
0 answers
43 views

How can I get the product permalink on the WooCommerce shop page?

I have tried several times to get the product permalink on the WooCommerce shop page, but I have a strange problem, the link appears in the Elementor editor, but not on the shop page. protected ...
Denis's user avatar
  • 1
0 votes
1 answer
48 views

How to make 2 (or more) custom post type post pages sit under the same slug?

I've created 2 custom post types like so: register_post_type( 'resources', theme_build_post_args( // $slug, $singular, $plural 'resources', 'Resource', 'Resources', ...
Freddy's user avatar
  • 147
0 votes
0 answers
21 views

Best way to approach creating a sitemap with unique URLS (No Permalink Changes)

I currently have been struggling mightily with a conundrum, I currently have a theme that is using day and name permalink settings so changing those settings are not possible, I'm attempting to make a ...
cluelessdeveloper's user avatar
0 votes
0 answers
18 views

how to properly format custom post type rewrite to get specific URL structure for archive and post views

The goal I created a custom post type for events listing and want to achieve the following URL structures all archives url This url returns 404 error https://example.com/events-list/ single archive ...
Nadal's user avatar
  • 89

1
2 3 4 5
64