Search redirects to index

The problem was due to htaccess file that was in the root directory. **`.htaccess`** DirectoryIndex start.php This was causing all of the index.php files to be changed to start.php. This filr did not exist in my wordpress directory. When I renamed the index.php to start.php in the wordpress installed sub directory the search started to … Read more

Search query with quotes

using the \’ escape works for me, so whatever is causing your issue is something else with your website. I checked with the code below: $the_query = new WP_Query( [‘post_type’ => ‘post’, ‘s’ => ‘Hello\’s’] ); if ( $the_query->have_posts() ) { echo ‘<ul>’; while ( $the_query->have_posts() ) { $the_query->the_post(); echo ‘<li>’ . get_the_title() . ‘</li>’; … Read more

Search results: How to add direct jump to anchor?

You should have the navigation menu with anchors on your page. <ol> <li><a href=”#products”>Products</a></li> <li><a href=”#examples”>Example</a></li> </ol> And the sections with relevant ID where are these anchors are linked to. <h2 id=”products”>Products</h2> After the changes are done, ask google to reindex your page and wait=) Here is detailed description: here

search this custom post type

Could you check one thing for me: http://codex.wordpress.org/Function_Reference/register_post_type When you register website_bookmarks is: exclude_from_search (boolean) (importance) Whether to exclude posts with this post type from search results. Set to false?