Hello again
I discovered that the text search in labellavita.no doesn't work. I'm referring to the "wp" search via the magnification icon in the top menu.
I have Relevanssi active on the site and it har worked fine previously (last checked... a year a go?)
I tried to follow the steps described here:
https://toolset.com/forums/topic/text-search-does-not-work-with-relevanssi-any-more-when-used-in-a-view/
and here:
https://toolset.com/documentation/user-guides/searching-texts-custom-fields-views-relevanssi/#including-custom-fields-in-the-search
But when doing a search I only get the front page.
The most important is that visitors can search for spesific locations (post type>house: title) and location (a custom field)
My best guess is that I have done something wrong here
hidden link
though I can't tell what.
Great if you can take a look
Thanks,
Kjetil
Hi, can you tell me more about this redirect:
hidden link
...redirects to...
hidden link
Therefore...
hidden link
...redirects to...
hidden link
This is probably why your search isn't working as expected, but I cannot explain why the redirect is happening.
Hi
Thanks for coming back to me
I set up the redirect because I needed the /house page as the site’s home page. I discussed this with you at support and this was the absolutely easiest way to do it. (If useful, it should be possible to find back to that thread, - just not for me now that I’m on a mobile 🙂
If you don’t have a great idea for that the best solution might be to remove the text search
Thanks
Kjetil
Just to elaborate:
I eg. hoped / tried to set /house as home page in the wp settings, but it is (was) impossible to make /house a “page”. Also just entering the /house url there wouldn’t work
....as I remember it
Kj
I understand, thanks. It seems like this was the ticket:
https://toolset.com/forums/topic/set-search-page-as-sites-home/
Shane recommended adding some custom code, and it looks like the redirect was added to your .htaccess file using a rewrite rule:
RewriteCond %{HTTP_HOST} ^.*$
RewriteRule ^/?$ "https\:\/\/labellavita\.no\/house\/" [R=301,L]
So my suggestions is either A or B:
A. Remove the text search from the main menu area, since it's not going to work with the redirect in place. WordPress Search results must be displayed at yoursite.com/?s=searchterm.
B. Modify this RewriteCond in your .htaccess file to ONLY redirect if there is no ?s search parameter in the URL. I'm not sure who made the updates in your current .htaccess file, but you may need their assistance to change this correctly. I'm not trained in .htaccess redirect rule syntax, and this isn't Toolset-specific so I don't want to give you some incorrect information here.
Thanks Christian, for sharing your insight!
I’ll ask around and see if I can go for B.
The only other - and better - solution I can think of is if one could apply a Toolset page to a WP “page” (and then set that as the site’s home), but you’d most probably mentioned that if it has become possible.
Thanks,
Kjetil