WebSite X5Help Center

 
Martin Gross
Martin Gross
User

Search field o page  en

Auteur : Martin Gross
Visité 2207, Followers 1, Partagé 0  
Mots-clés :: search

Hello,

is there a possibility to put a search field into a page instead of into the header or footer?

I only want the search to appear in the e-shop section.

Thank you

Martin

Posté le
5 RéPONSES
Anthony A.
Anthony A.
User

use the code that search field generates and add it into html object in any pages you wish to have the search bar

if this post is the correct answer, please mark this answer as correct answer.

------------------------------------------------------------

Good Luck
https://nuluhost.com (compatible with x5 program, 30 days money back guarantee)
http://www.wdesigners.us (new)
http://www.usx5.com (coming soon)(Sign up)

Lire plus
Posté le de Anthony A.
Martin Gross
Martin Gross
User
Auteur

Hi Anthony,

thank you for your reply. I am not a very code savvy person, this is why I use Website X5. Could you please give me a hint where to find that code?

Also I would like to know if there is a possibility to limit the search only to specific pages or if the search function always searches the whole site.

The situation is as follows. I have an e-shop with veterinary products and pet food and I have for example cat and dog food from the same brand and I want the customer to be able to search only in the section in which he currently is. So that when he is in the cat section and searches for i.e. Royal Canin, the search returns only Royal Canin cat food, but not Royal Canin dog food. Is that possible?

Lire plus
Posté le de Martin Gross
Anthony A.
Anthony A.
User

Marting, this is the code you need to use (hopfully forum will show it all to you and not removing some of it)

as far as limitting the search, no, you can not limit it, it will search your entire website.

<div class="search_form" style="position: absolute; top: 15px; left: 163px; width: 120px;"><form id="imSearch_1" action="imsearch.php" method="get" style="white-space: nowrap"><fieldset><input type="text" name="search" value="" style="width: 153px; line-height: 22px; font: normal normal normal 8pt Tahoma; color: #000000; background-color: #ffffff; background-image: url('res/imsearch.png'); background-position: 2px center; background-repeat: no-repeat; padding: 3px 3px 3px 22px; margin: 0; border: 1px solid #000000; vertical-align: middle; border-top-left-radius: 5px; border-top-right-radius: 5px; border-bottom-left-radius: 5px; border-bottom-right-radius: 5px;" /><span onclick="$('#imSearch_1').submit();" style="height: 23px; font: normal normal normal 8pt Tahoma; color: #000000; color: #000000; background-color: #D3D3D3; margin-left: 5px; padding: 3px 6px 3px 6px; border: 1px solid #000000; vertical-align: middle; cursor: pointer; border-top-left-radius: 5px; border-top-right-radius: 5px; border-bottom-left-radius: 5px; border-bottom-right-radius: 5px;">Search</span></fieldset></form></div>

if this post is the correct answer, please mark this answer as correct answer.

------------------------------------------------------------

Good Luck
https://nuluhost.com (compatible with x5 program, 30 days money back guarantee)
http://www.wdesigners.us (new)
http://www.usx5.com (coming soon)(Sign up)

Lire plus
Posté le de Anthony A.
Martin Gross
Martin Gross
User
Auteur

Thank you very much, Anthony. I will give it a try.

Anyway, I just realize that the search will only return just the pages that fulfill the given search criteria, not a page with the products in question. Am I right?

Lire plus
Posté le de Martin Gross
Anthony A.
Anthony A.
User

search will read your entire website, there is no setting to divide that.

if this post is the correct answer, please mark this answer as correct answer.

------------------------------------------------------------

Good Luck
https://nuluhost.com (compatible with x5 program, 30 days money back guarantee)
http://www.wdesigners.us (new)
http://www.usx5.com (coming soon)(Sign up)

Lire plus
Posté le de Anthony A.