开发者

How can i redirect to my own page in wordpress?

In wordpress if pages are not found it automatically redi开发者_JAVA技巧rects to 404 page. but i want to redirect to default page which is i created in the same theme (without redirection to 404 page) when the pages are not found. how can i do this?...

Thanks Ravichandran


ErrorDocument 404 /default.php

Add this in .htaccess file


you can edit the 404.php file, and then add the following line:

header('location:your-domain-name.com');

or you can redirect to some php file also:

header('location:default.php');

Simple trick. It works for me.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜