Can anybody please tell me how to customize my search facility so that the quick search results show only hits from the product title and the product attributes, excluding the product description.
Thanks in advance.
Can anybody please tell me how to customize my search facility so that the quick search results show only hits from the product title and the product attributes, excluding the product description.
Thanks in advance.
I do not believe product_attributes is used in the search. However, if you know how to program you can look in the search code and modify the code so that product_description is not used.
I believe this is the file to modify
/public_html/includes/languages/english/advanced_search_result.php
Um, no, you won't find it in a language file.
To tell the search not to use the description, simply set the right parameter: Use the Developers Toolkit and search the catalog-side template files for search_in_description = 1 and change it to 0 instead of 1 in the appropriate file ... typically either tpl_search.php or tpl_search_header.php depending on which search box you're using.
.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole
Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.
Thank you for that Dr Byte, will look into that. Is there any way to include attributes in the search results?
Including attributes in search results will require custom coding, as that's not a built-in feature at the present time.
You can post an ad for paid help in the Commercial Help Wanted section of the forum if that's something you're interested in.
.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole
Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.
A million thanks Reuben
Can you work your mojo on the attribute search problem too?![]()
On my version, the code is not
search_in_description = 1
but
'search_in_description', '1'
and you can find it in two files:
/includes/templates/template_default/sideboxes/tpl_search.php
and
/includes/templates/template_default/sideboxes/tpl_search_header.php
If you want to change this, move the files to:
/includes/templates/YOUR_CUSTOM_TEMPLATE/sideboxes/
and edit the line
'search_in_description', '1'
to be
'search_in_description', '0'
Hope this helps.