{"id":2904,"date":"2026-10-20T08:37:21","date_gmt":"2026-10-20T07:37:21","guid":{"rendered":"https:\/\/wpgeodirectory.com\/documentation\/article\/search-autocomplete-opens-result\/"},"modified":"2026-10-20T08:37:21","modified_gmt":"2026-10-20T07:37:21","slug":"search-autocomplete-opens-result","status":"publish","type":"gd_place","link":"https:\/\/wpgeodirectory.com\/documentation\/article\/advanced-search\/search-autocomplete-opens-result\/","title":{"rendered":"Search autocomplete opens a result before I enter a location"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">That is how the Advanced Search Filters autocomplete works by default. Clicking a suggestion takes the visitor straight to it: a listing suggestion opens that listing, and a category suggestion opens the category page. The search form is not submitted, so the Near location is not used.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Make category suggestions wait for the search button<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">In the Advanced Search settings, find the &#8220;Category selected action?&#8221; option and set it to &#8220;Fill in search and await user submit&#8221;. A category suggestion then fills the search input and the visitor can add a location before pressing search. There is a matching option for tag suggestions.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Listing suggestions always go directly to the listing.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Other ways to set it up<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Show only category suggestions with the &#8220;Show search suggestions with&#8221; option set to Categories Only.<\/li>\n\n\n\n<li>Turn the autocompleter off with &#8220;Enable search autocompleter?&#8221; and add a category dropdown to the search bar instead. See <a href=\"https:\/\/wpgeodirectory.com\/documentation\/article\/advanced-search\/how-to-add-a-filter-to-the-main-search-bar\/\">how to add a filter to the main search bar<\/a>.<\/li>\n\n\n\n<li>If you use a category dropdown, you can hide the keyword input with the &#8220;Hide Main Search Input&#8221; option on the GD > Search block, leaving the category and Near fields.<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">A single search bar that switches between &#8220;search by category&#8221; and &#8220;search by name&#8221; is not built in. You can place two GD > Search blocks set up differently, for example one with the keyword input hidden and one with only the keyword input.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>That is how the Advanced Search Filters autocomplete works by default. Clicking a suggestion takes the visitor straight to it: a listing suggestion opens that listing, and a category suggestion opens the category page. The search form is not submitted, so the Near location is not used. Make category suggestions wait for the search button [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"","ping_status":"closed","template":"","meta":{"footnotes":""},"article\/tags":[],"article\/categories":[213,400],"class_list":["post-2904","gd_place","type-gd_place","status-publish","hentry","gd_placecategory-extensions-features","gd_placecategory-advanced-search"],"_links":{"self":[{"href":"https:\/\/wpgeodirectory.com\/documentation\/wp-json\/wp\/v2\/article\/2904","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wpgeodirectory.com\/documentation\/wp-json\/wp\/v2\/article"}],"about":[{"href":"https:\/\/wpgeodirectory.com\/documentation\/wp-json\/wp\/v2\/types\/gd_place"}],"author":[{"embeddable":true,"href":"https:\/\/wpgeodirectory.com\/documentation\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/wpgeodirectory.com\/documentation\/wp-json\/wp\/v2\/comments?post=2904"}],"version-history":[{"count":0,"href":"https:\/\/wpgeodirectory.com\/documentation\/wp-json\/wp\/v2\/article\/2904\/revisions"}],"wp:attachment":[{"href":"https:\/\/wpgeodirectory.com\/documentation\/wp-json\/wp\/v2\/media?parent=2904"}],"wp:term":[{"taxonomy":"gd_place_tags","embeddable":true,"href":"https:\/\/wpgeodirectory.com\/documentation\/wp-json\/wp\/v2\/article\/tags?post=2904"},{"taxonomy":"gd_placecategory","embeddable":true,"href":"https:\/\/wpgeodirectory.com\/documentation\/wp-json\/wp\/v2\/article\/categories?post=2904"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}