This (in your functions.php
) will turn it off (but see also the comment I’ve left):
remove_action('template_redirect', 'wp_old_slug_redirect');
It seems odd that your wp_postmeta
table wouldn’t have any _wp_old_slug
keys – the bit of code that does that is in wp-includes/query.php
(wp_old_slug_redirect()) – you could add an exit or debug statement there to check if it’s being called.
Also, remember that if WordPress can’t find a permalink, it looks for posts with a matching beginning, e.g. if you had a post with permalink /foobar, then /foo will redirect to it.
Related Posts:
- How can I force WordPress to redirect to canonical permalinks?
- Does rename of page slugs create 301 redirects from old slug to new (same as for posts)?
- I’ve removed my /author/ slug but it clashes with new and existing pages. Any fixes?
- Pages resolve at different URLs (different capitalizations)
- WordPress not remembering old slugs for pages
- How does WordPress handle permalinks?
- WordPress slug issue with non-latin characters
- Change slug on post creation
- Is It A Good Idea To Change Author Slug (user_nicename field) Directly In MySQL DB?
- When creating a WordPress page, a “-2” suffix is added to new pages’ permalinks
- Passing variables through permalink structure
- + Character in permalink
- How to Remove Slug From Database?
- Permalink redirection from ‘Day and name’ to ‘Post name’
- Remove parent slug for child pages
- Nicest way to 301 Redirect traffic when changing permalink settings
- Replace WordPress %postname% suffix with %postid%?
- Changing pemalink structure to /%post_id%/%postname%/
- htaccess or redirect to cloak portion of a link?
- Redirect short-form URL to long-form URL (post_id to post_id + post_name)
- Auto 301 to full post permalink? (using /posts/%post_id%/%postname%)
- Stop redirecting to posts not in a category / duplicate slugs
- Redirect old permalinks with Month and name to Post name on new site
- Make attachment pages require a base url
- .htaccess – Redirect duplicated post ended in ‘-number/’ to the same url without the -number/
- Top level Pages redirecting to homepage!
- Is using %postname% for permalinks really that bad for performance?
- How to 301 all posts
- WordPress within specific sub-directories, implicitly not root
- Change author slug and functionality
- Get canonical link
- How can I add a page’s ID to its permalink using WP_Rewrite?
- How to modify the slug for the default wp posts without affecting other posttypes?
- If I change permalink structures, can I use htaccess to permanantly redirect links?
- Redirect parent taxonomy to it’s child
- Custom Permalink
- Change permalinks on move from one site to another
- Non latin post slug truncate
- filtering special chars from post slug
- Share same Slug for a Custom Post Type and 2 Taxonomies
- Redirects after permalink change
- How to 301 redirect from one url to another properly
- Redirect a Blogger Page URL to wordpress
- wp not making CPT permalink / slugs unique
- Edit page slug after save, cause 404 by linked pages
- WordPress 4.4 old permalink redirect
- Htaccess https 301 problem
- Passing the JQuery string to Worldpress URL
- How to use different domains for different blogs hosted in the same host in subdomains with .htaccess
- Custom permalinks in WordPress
- Freeze child page URLs so parent permalink changes don’t give 404s?
- How can I make internal anchor links work with WordPress’s permalinks?
- What causes /pages/ to appear in URI, and how to remove it?
- wordpress how to replace url /bar with foo/bar for custom post type
- Some Pemalink problems, probably caused by wrong .htaccess configuration?
- Strange behavior with a redirect loop – involves WPML multi-language plugin
- Redirect From Url To Url
- how do prevent wordpress from creating permalinks for media files
- After cloning WP do a subdirectory, I can’t access it
- Bulk append URL (add word to slug)
- change WordPress permalinks and redirect new urls 301
- Arabic permalink redirect to home page
- Configuring Home Page Address
- Remove international characters from slug – Almost done – Bit help
- Change url of page according to my requirements in wordpress
- Gutenberg Editor: dynamically edit slug field based on ACF field
- How to redirect old permalinks from https://exmaple.com/category/post_id to https://exmaple.com/category/post_id.html
- New posts link to old posts (random)
- Modify post slug before saving
- Does wordpress take care of slug collisions?
- corrupted URLs – can’t leave starting page
- WordPress slug confusion
- Redirect old /%category%/%postname%/ to just /%postname%/
- Code snippet to add filter pre_post_link to change Media URL (post_type attachment permalink/slug)
- home page slug editor missing from WordPress
- 301 redirects after changing permalinks
- How to experiment with permalink structure on a select number of posts
- Change permalink structure with post id
- How to allow different authors to use same post slug?
- redirect any category in URL to the ID and post-name only – hundreds of pages affected
- Problem with permalinks
- Post redirected to page with same name but DIFFERENT permalink
- Changed Permalinks settings, how do I redirect posts on Nginx?
- Post permalinks go to the home page
- Force/Limit the post/page slug to accept only url friendly characters
- Can’t access WordPress site in subfolder possibly because of .htaccess redirect from root installation?
- changing permalink gives 404 error for old links
- Uppercase vs. Lowercase page slugs
- Is there a way to remove the option to modify the Slug in post.php
- Possible to hide parts of the slug from get_template_directory_uri and bloginfo(‘template_directory’)
- How to update permalink on the fly?
- Removed and Reinstalled WordPress, Redirect Broken now
- redirect old pages by .htaccess
- Why are all pages redirecting to homepage when using custom permalinks?
- Redirecting From An Old Permalink Structure
- Display a custom slug in URL depending on user variable
- .htaccess regex for redirect subdomain to root domain & redirect old permalinks
- Different template fallback when changing permalinks
- 301 Redirect posts to newly added categories
- UI does not show correct Slug after modified using save_post action