admin管理员组文章数量:1391991
I have noticed that on my wordpress installation the page
domain/test?page=2
is redirecting to
domain/test/2
I tried disabling all plugins and also used the default/different themes and the behavior exists nevertheless, why I am assuming that this is a wordpress behavior.
Is there any chance to prevent this redirect and keep the ?page parameter intact in the URL?
I have noticed that on my wordpress installation the page
domain/test?page=2
is redirecting to
domain/test/2
I tried disabling all plugins and also used the default/different themes and the behavior exists nevertheless, why I am assuming that this is a wordpress behavior.
Is there any chance to prevent this redirect and keep the ?page parameter intact in the URL?
Share Improve this question asked Mar 26, 2020 at 18:22 TomTom 1114 bronze badges1 Answer
Reset to default 0Any reason why you need to keep the ?page= in the url? If you just need to get the value of the page you can use:
// will return value after "paged" pages "test/page/2" $paged will be 2
$paged = get_query_var('page');
本文标签: redirectwordpress automatic URL 39page39 parameter rewrite
版权声明:本文标题:redirect - wordpress automatic URL 'page' parameter rewrite 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1744631624a2616574.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论