PHOENIX CART SMART SEARCH — V1.1.5

Smart Search replaces the standard Navbar search popup with an inline search field and live suggestions.

FEATURES
- Searches active products by name and model number, then fills remaining suggestions with product description matches. Full search also includes product descriptions.
- Searches published Info Pages in the current language.
- Offers spelling corrections when there are no direct matches.
- Shows a short matching description from its beginning under product and Info Page suggestions, with UTF-8-safe truncation.
- Pressing Enter opens a hovered or keyboard-selected suggestion. With no suggestion selected, it shows the full search results.
- Opens product and Info Page suggestions directly.

INSTALLATION
1. Upload all files in this package to the shop root, preserving the folder structure.
2. In Admin, open Modules > Navbar and install “Smart Search”. Set its placement and sort order.
3. Disable the standard “Search” Navbar module to avoid showing both search controls.
4. Test product names, model numbers, descriptions, Info Pages, and typo corrections on a test copy.

PACKAGE FILES
- smart_search_suggest.php
- includes/modules/navbar/nb_smart_search.php
- includes/modules/navbar/templates/tpl_nb_smart_search.php
- includes/languages/english/modules/navbar/nb_smart_search.php
- includes/js/smart_search.js

The JavaScript file supplies the suggestion behavior and dropdown styling. No separate stylesheet, core-file changes, or database changes are required.

V1.1.5 — CLEAN PRODUCT LINKS
Adds includes/hooks/shop/system/_00SmartSearchProductLinks.php.
The early hrefLink hook removes search_in_description from product_info.php
links before Phoenix and SEO URL hooks render them. This also cleans the
product Add to Cart form action when an old link still carries the parameter.
The original search_in_description field remains on the full results search
form, preserving description searching. Other URL parameters are retained.

UPGRADE FROM V1.1.4
Upload the new hook file to the same path under the store root. No admin
reinstallation, database changes or Phoenix core changes are required.
The full package includes all original V1.1.4 files plus this new hook.
Keep Add to Cart Popup V1.0 while testing this search fix; the separate
experimental popup V1.0.1 direct-URL workaround is not required for this test.

CHECK ON THE TEST STORE
Search for mort, press Enter without selecting a suggestion, and open the
product from the full results. Its URL should omit search_in_description.
Add it to the basket and confirm the popup opens with the correct quantity.
Also check a direct suggestion and a product with options. Open an old product
URL ending ?search_in_description=1 and check Add to Cart there as well.
Description searches should continue to work in the full results page.

VALIDATION
Hook ordering checked against official Phoenix v1.1.0.6: the new _00 hook runs
before the standard _01_href_link renderer. Existing search files are unchanged.
PHP execution and the installed USU hook order could not be tested locally;
please verify the behaviour on your test store before live installation.

REMOVE FIX
Delete includes/hooks/shop/system/_00SmartSearchProductLinks.php.
