Reply To: Category search displays blank search results on desktop; works fine on mobile

Home Forums Product Support Forums Ajax Search Pro for WordPress Support Category search displays blank search results on desktop; works fine on mobile Reply To: Category search displays blank search results on desktop; works fine on mobile

#12584

Ernest Marcinko
Keymaster

Hi!

I believe I see the problem here. I'm not sure, but based on the page source, I see you use plugin shortcode in your header, which was made with the shortcode builder. The problem comes from the fact that it was mostly made to display the search in a block-styled fashion, within a page content, where there is enough space. However the site header is not the best use case of that shortcode. In your case this simple shortcode is:

[wd_asp id=2]

Instead, I would suggest using the simple search shortcode, and making sure that the results and the settings box layout is both set to 'hovering' as well. This way, the results and the options will be displayed directly below the search, floating above the content.
– Results layout mode: https://i.imgur.com/vmSni8q.png
– Settings layout mode: https://i.imgur.com/2ibyF73.png

Another thing is the search bar final width for the compact layout. By default it's set to '100%', meaning, that it should stretch to the container element, to adopt it's width. However in this case, the container element itself is moving around and changing it's width on some conditions. I would also recommend changing this to a fixed, pixel value, for example '320px': https://i.imgur.com/pKRbSNR.png
This will help you maintain the element position in the header.

The 'no results' issue I believe is in connection with the taxonomy term filters, because I see that their default state is set to unchecked: https://i.imgur.com/55AvNvf.png
Therefore even if the keyword matches a result, the category it belongs to might be unchecked. You can change this state back to checked on the Frontend Search Settings -> Categories &Taxonomy terms panel: https://i.imgur.com/dpgfrup.png

Best,
Ernest Marcinko

If you like my products, don't forget to rate them on codecanyon :)