Articles of 404 error

Multiple 404.php templates based on a post_type

Is it possible to have different 404 templates based on the post_type? So when page is not found 404.php will be used, when post is not found 404-post.php will be used. Or alternative, I would like just to display different message when blog post (post_type=post) is not found than when page is not found (post_type=page). […]

Get the search element only on 404

I know get_sidebar( ); is used to get the widget sidebar , but how do I request one element from it? For instance, if I want to show the search or most read only? I know there is a way to specify the sidebar for page like get_sidebar(‘404’ ); for example How do I do […]

WordPress overrides custom 404 page with it's own

I want to create a custom 404 page, but I cannot seem to override the 404 which is in WordPress itself. The reason I want a custom 404 page is that if I get 404 within my subdirectories I get directed to my wordpress-site’s 404. I’d rather have a 404 for my whole domain. I’ve […]

404 Admin Error

I am new to WordPress and was looking at settings in the admin. I believe I changed the directory of the site from to When I saved the changes I immediately saw a 404 error that says: Not Found The requested URL /index.php was not found on this server. Additionally, a 404 Not […]

Need 404 behaviour for blank parent page

My pages look like this Home (Has content) Products (No content) Product 1 (Has content) Product 2 (Has content) Product 3 (Has content) Contact (Has content) I only created the “Products” page so the navigation makes sense in the Pages structure, however it has no content so I need it to show the 404.php when […]

Fix 404 error after changing permalink structure

hope you are all doing good! I have this problem. I had set “Post Name” as the URL scheme, therefore, I get for blog entries. I’ve written a few test posts and I realize I want permalinks to look like this: For blog posts: For categories: For tags: So I made […]

No 404 page available

There is 404.php in the theme uploaded. But when there is search for non-existent page. The 404.php does not show up. What is the reason? Assistance required.

404 not working on main site on multisite

I currently have two sites(main site and sub site) created with multisite function. Recently, i noticed that the 404 error page seems not to work on main site. No matter what error url i type to test the error page, it takes me to home page instead of 404 page. But, it is working fine […]

Accidentally deleted php code in WordPress website

I have a website: . While trying to remove the “continue reading”, I accidentally deleted some code and updated it in the theme editor‘s functions.php. Now the website does not work and here is the error code Parse error: syntax error, unexpected ‘}’ in /home2/efulas/public_html/wp-content/themes/catch-box/functions.php on line 395 How can I fix this?

Custom post type single (permalink) throws a 404 error

I’m working on a website that has Woocommerce installed (also a CPT if I’m right, but that one works fine). This website has a custom post type for jobs, this cpt has posts that are linked to in the website via their permalink. The post type works fine in the admin panel but that’s as […]