Now the question is why does WP only put the word “date” in when the permalink is “/%post_id%/%postname%/”?
Because the WP_Rewrite class method get_date_permastruct only looks specifically for a clash between %date% and %post_id% tags.
To get this date structure with other numeric-based post permalink structures, you can manipulate the date structure directly:
function wpa57228_date_structure() {
global $wp_rewrite;
$wp_rewrite->date_structure = $wp_rewrite->front . 'date/%year%/%monthnum%/%day%';
}
add_action( 'init', 'wpa57228_date_structure' );
Related Posts:
- Archive permalinks
- Permalinks for WooCommerce Categories and Subcategories
- Rewrite url / permalink for default archive – yearly / monthly
- Change of permalink structure – redirects in htaccess breaks the archive links
- Custom permalink for search and pagination
- Programatically changing post’s permalink when identical post type is published
- Date Archives’ Permalinks under Category folder
- Can’t select blog month within archive category
- Advanced author permalinks
- Disable date based archives for all categories except one
- Path to Pages Resolves to Archive instead of Actual Content
- Change permalink structure for pagination only
- I Need to use Month , year in my all archives and pages of my wordpress site
- Strip subcategory base from URL
- archive by year and category: permalink support doesn’t work on pagination
- Customize URL for specific tags archive
- Permalinks – Archives
- WordPress Archives Cause Looping
- Permalink, links a page to the homepage
- Permalinks of archive tag wordpress
- WordPress archive posts returns user to homepage
- Post archive pages bringing me to a 404 page
- Strip category base from URL?
- where is permalink info stored in database?
- How can I reverse engineer a Permalink to Find the Page?
- Mapping Domains to Permalinks (not multisite)
- How to remove dates from existing permalinks?
- Force WordPress to Show Pages Instead of Category
- How would I create a different permalink structure for pages and posts?
- My permalinks are broken! Can I use mod_rewrite to ignore a physical file?
- How to prevent the default home rewrite to a static page
- Is there an action for when permalinks are rebuilt?
- When creating a WordPress page, a “-2” suffix is added to new pages’ permalinks
- mod_rewrite enabled but Permalinks show index.php
- How to get url of a post from admin panel
- How to get a page url by a page id?
- CPT archive 404ing when using a custom taxonomy name as a variable
- How to change “permalink” structure in “WordPress Thesis” theme?
- Turn off %postname% auto-incrementing?
- Custom Taxonomy URL
- rewrite_rule for custom post type doesn’t affect get_permalink
- Add ‘articles’ prefix before blog posts url without affecting pagination
- Custom attachment permalink structure [closed]
- WordPress not respecting template hierarchy (fetches index.php instead of single.php or page.php)
- Is there anything built into the WordPress core to enable me to get the relative path from the “permalink structure” option
- Permalink change made author archive vanished
- Get page by path – honoring permalink settings (urls w/slashes)
- Pagination Issue – /page/2 404
- How to stop WordPress from removing & from URL?
- Nginx Rewrite Rule:: index.html added to every permalink
- Share same Slug for a Custom Post Type and 2 Taxonomies
- Custom Post Type Yearly Archive Permalinks
- How to prevent redirect when using the term “page” in query string?
- Post preview gives 404 when permalinks are purely date based
- .htaccess rewriterule being ignored – tyring to remove dates from WP posts
- How to redirect RSS feeds to Feedburner and keep pretty permalinks?
- Apply function only if end of url has /amp/ [closed]
- Permalinks – .htaccess
- WordPress Permalinks 404 bug with “next” button
- Combine category AND custom taxonomy in permalink structure
- home_url on IIS missing permalink index.php
- Update the permalinks in posts (not domain change)
- permalink and add_rewrite_rule – error 404
- Remove Parents From Permalink of Hierarchical Taxonomy
- WP-e-commerce (getshopped) – Annoying permalink issue [closed]
- Default Permalink Structure for Pages
- IIS7.5 URL rewrite pboblem on index page
- Category blog URL 404
- Read more block is appending /#more-{post_id} to the link
- URL getting changed
- Edit the output of a filter
- Why does one of my pages not have the option to edit the link?
- Custom Permalink Structure for The Events Calendar
- WP permalink working, but why content doesn’t display
- Giving specific category posts its own permalink structure returns 404
- I have Akamai pointing to a WordPress installation with a different URL. Is there a way to make WordPress use this for link generation?
- Issue with wp_insert_post when modifying permalinks with “.html” extension
- Permalink like example.com/taxonomy/post_type/postname
- while changing permalink, page redirected you too many times
- WordPress – Permalink custom Structure – 404
- how to have same rewrite rules for 2 different post type?
- How can I add my own ‘read more’ or ‘after the jump’ type of link to the article page?
- Issue with my links or permalinks
- Why can’t I save permalink “360” for a page?
- Internationalize Forum Posts Without Translating Them
- How to change permalink structure and keep permalinks for old posts
- Pointing, two or more archived Blog posts to the same permalink (Single post page)
- Where is wordpress redirecting wp-admin/admin/dashboard to wp-admin and how to turn it off
- Is there a way to remove the option to modify the Slug in post.php
- Issues with WordPress permalinks
- Only homepage working correctly, 404 error on everything else
- Text in permalink
- custom permlink .htaccess file 404 Not Found error
- How to shorten the Permalink after WP>WP blog import?
- Ugly permalinks stopped redirecting to pretty URLs
- Add segment to URL in htaccess
- Single product link in woocomerce
- Facebook like button disappears after changing the static permalink to dynamic one!
- URL issues with WordPress
- Display the content of another page from a specific URL