Hi,
I would like to change url structure for archives to not include “page” slug anymore.
For example archived articles are listed in this organisation:
mydomain.com/page/01 -> mydomain.com/01
mydomain.com/page/02 -> mydomain.com/02
mydomain.com/page/03 -> mydomain.com/03
How can I do that with htaccess or functions.php? I already have permalinks structure set properly to /%category%/%postname%/ so that they show with corresponding archive name. If anyone know how to do rewriterule, kindly let me know.
]]>Add this code to your functions.php file.
add_action( 'init', 'remove_page' );
function remove_page(){
global $wp_rewrite; $wp_rewrite->pagination_base = "";
}
Please backup your website.
Hope this will help.
Thanks.
]]>mydomain.com//01
mydomain.com//02
mydomain.com//03
Thanks for answer anyway.
]]>