WP permalink handling is sort of layered. They underlying “ugly” permalinks capture the actual logic of the system and the “pretty” permalinks are just cosmetic enhancement on top of it.
Even when pretty permalinks are enabled, the original ugly permalinks still continue to work. But under normal circumstances they get redirected to a pretty version.
You could selectively kill pretty redirect with something like this:
add_filter( 'redirect_canonical', function ( $redirect_url ) {
if ( is_paged() ) {
return false;
}
return $redirect_url;
}, 10, 1 );
Though this won’t affect how links are generated, so API functions which deal with pagination and stuff will still output pretty results. It’s probably quite involved to override this comprehensively.
Related Posts:
- add_feed rewrite overwriting standard permalinks
- How to add rewrite rule for product compare page?
- Custom pages with plugin
- Change the “page” slug in pagination
- WordPress Paginate $wpdb->get_results
- Multiple post types – share same ReWrite slug?
- Problem with add_rewrite_rule and pagination (paged and page query_vars)
- Need help with friendly URL’s in WordPress
- Disable wordpress pagination URL rewrite for specific page
- How to build custom WP admin with custom URLs
- WordPress in “Couch Mode”?
- pagination in woocommerce order history page
- Add ‘articles’ prefix before blog posts url without affecting pagination
- How can I rewrite a plugin generated URL?
- How to change URL Custom Page?
- Remove “/page/1” from the URL
- add_rewrite_rule won’t work
- Pagination problem
- Remove Author Slug & Replace With Username
- Adding Pagination on a Custom Author Page
- Fatal error: Call to a member function add_rewrite_tag() on a non-object in /wp-includes/taxonomy.php on line 333
- Paginate Author’s Post List on Custom Author Page (ANOTHER THEORY)
- Why is my mod_rewrite not working?
- Disable Pagination on Pages
- Pagination Issues using WP_Paginate Plugin
- URLs and navigation in custom themes
- Changed pagination URLS to use p= instead of paged=
- redirect post id to post full url
- Taxonomy Pagination Rewrite
- 404 (category, pages, archives) when using custom rewrite rules
- WordPress 3.0.1 on IIS 6 Web Server PermaLink Issues
- How do I redirect a post url to a custom url?
- Adding a rewrite rule to page that has no fixed variables and pagination
- Hide text if not homepage
- Is there a way to by-pass the pagination function on one custom template?
- Is it advisable to use `add_rewrite_rule()` to serve a custom page?
- Rewrite with pagination /foo/page/2/ to posts of a given category, page 2
- How to custom post navigation
- Many Rewrite Parameters/Rules
- Pagination with custom field
- Pagination for custom post types – url rewriting
- Why is a rewrite rule in wordpress prevent pagination?
- WordPress pagination with custom post type?
- How do I run a web app in my WordPress theme without the “wp-content/theme/…/webapp” in URL?
- I want to change url structure of my created archieve pages
- Custom query pagination with php parameter as arg problem
- Url rewriting on custom post with CPT UI plugin
- Page Permalinks: Custom URLs
- Custom pages with plugin
- Paging not working for hierarchical custom post type
- WordPress custom search – pagination
- Rewrite Rule & Regex – Extract ‘cat-name’ and ‘page-number’ from http://domain.com/custom-post-type/category/cat-name/page/page-number
- Pagination is not working on custom query
- wp_rewrite not working on third level url
- Show post content in two different places without redirect
- Gallery Pagination by Row
- Instead of Custom CSS Theme CSS is loading
- Wrong rewrite rules
- wordpress category rewrite rule with pagination
- Create a page for each database table entries
- How do you create a “virtual” page in WordPress
- Can You Export Theme Settings From WordPress Multisite?
- Adding Custom Fields to WordPress Comment Forms?
- How Can A Widget With Only One Instance Be Defined?
- Getting $comments outside the comment template
- Find and replace domain name on the fly?
- What is the most idiomatic way to let clients edit phrases in HTML?
- How to change “Dashboard” text in wordpress
- changing comment-page-# to something like review-page-#
- Call to a member function add_rule() on a non-object
- Remove url rewrites for registered taxonomies
- @font-face is not working in WordPress
- What changes we need to make to a theme so it can be installed as a MU Theme?
- Get Custom Logo Alt Text
- result from custom filter admin table list backend does not work
- WordPress keeps writing rewrite rules to .htaccess
- Blog page problems
- Installing new theme on running site
- How to format text of site subtitle
- WordPress broken after domain name change
- How to Restore Deleted Post Not in Trash
- Display content of metabox if filled in
- Custom Post Type, post-formats associated to custom post type > 404 archives
- User profile Pick a premade Design/theme
- i want to rewrite my custom plugin url
- Recent activity query WordPress
- website is not loading home page (moving from one server to another server)
- Swap home page based on user role, Elementor layout breaking
- Customized Blog/Latest Posts Page
- Password Protection issue
- how to edit or remove the dashboard footer message [duplicate]
- Translate site in own text-language [closed]
- Permalink structure not working with Custom Taxonomy (URL like ./taxonomy/category/postname)
- How to work around the bug which prevents custom menus from being deleted?
- Rewriting WordPress URLs
- How to remove the tagline from the HTML ?
- Custom table or form
- How to Rewrite WordPress URL for a Plugin
- How I can add blog in my magento site?
- Adding Telescope / Meteor App to existing WordPress site