X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Changing design (https://forum.x-cart.com/forumdisplay.php?f=51)
-   -   Search by SKU only (https://forum.x-cart.com/showthread.php?t=23242)

mikalou 07-13-2006 06:26 AM

Search by SKU only
 
I want to place a second search box on the home page that will allow a customer to search by SKU only. So, if a customer types: "12345" (without quotes) in this second search box, the search will only look for that exact value in the SKU field.

In other words, a search for keyword 12345, would return search results that include only the product with SKU 12345 and not the product with SKU 123456. Nor would it return a product with 12345 in any of the other fields such as description, manufacturer, etc.


I have already added:
Code:

<INPUT type="hidden" name="posted_data[by_productcode]" value="Y">
to: customer/search.tpl, which allows the customer to find a product based on a SKU however doing this just adds the SKU to the fields that will be searched. That's okay, but I want a second search box that will allow the customer to search on the SKU only.

I've searched forums extensively for this exact feature but to no avail. Any assistance would be much appreciated.

balinor 07-13-2006 08:31 AM

Please don't post questions in the Completed Custom Mods forum. Moving to Template Editing.


All times are GMT -8. The time now is 07:48 PM.

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.