Tag Info

Hot answers tagged

1

You should set your publicly_queryable argument to true when registering your custom post type. TAKE NOTE: Add flush_rewrite_rules(), refresh the page once or twice and REMOVE IT IMMEDIATELY. You SHOULD NOT keep flush_rewrite_rules() unless under the provisions as in the codex. this is an expensive operation so it should only be used when absolutely ...


1

You can include the search form in your 404.php file using the get_search_form() function. Using get_sidebar( '404' ); would look for a file called sidebar-404.php and fall back on sidebar.php if needed. get_sidebar()


1

It is possible but wordpress doesn't have any helpful constructs to help with that. The best approach is to modify your 404.php. Most of the information that you need should be in the main WP_query object and you should be able to do something like if (is_singular('post_tyoe_a')) { .... } else { .... } this is extremely untested and you might need ...



Only top voted, non community-wiki answers of a minimum length are eligible