Replies: 0
I have a site in spanish and need the pagination slug to be in spanish.
I changed the rewrite rule with an action in my custom theme’s functions.php file.
function re_rewrite_rules() {
global $wp_rewrite;
$wp_rewrite->search_base = 'buscar';
$wp_rewrite->pagination_base = 'pagina';
$wp_rewrite->flush_rules();
}
add_action('init', 're_rewrite_rules');
I’m using the Posts widget with the «Load More» option, and when loading more content, the slug changes to “…/catalogo/page/2/” instead of “…/catalogo/pagina/2/”.
This causes that when clicking on a post and then browsing back, the page is not found.
However, if entering the url with the right page slug (…/catalogo/pagina/2/) the results show correctly.
Is there a way to change the slug used to update the address bar when clicking the Load more button?
Much appreciated.