Hi,
I'm using Smile SA module for layered navigation and search autocomplete and these all are working fine. But when i added custom dropdowns to filter products based on Category and Brand.
For example
And here is my additional code for select dropdowns
<div class="search_dropdowns">
<select id="select-category" title="Select your category" name="cat">
<option value="0" selected>Categories</option>
<?php
foreach ($categories as $category) { ?>
<option value="<?php echo $category->getId(); ?>"><?php echo $category->getName(); ?></option>
<?php } ?>
</select>
<select id="select-brand" title="Select your brand" name="manufacturer">
<option value="0" selected>Brands</option>
<?php
foreach ($brands as $brand) {
if ($brand['value'] != '') {
echo "<option value='" . $brand['value'] . "'>" . $brand['label'] . "</option>";
}
}
?>
</select>
</div>
And the script which passes the query string in the url as below:
<script type="text/javascript">
//<![CDATA[
var searchForm = new Varien.searchForm('search_mini_form', 'search', '');
searchForm.initAutocomplete('<?php echo $helper->getSuggestUrl()?>?cat='+jQuery('#select-category :selected').val()+'&manufacturer='+jQuery('#select-brand :selected').val(), 'search_autocomplete');
//]]>
</script>
Here is my urls when searching something:
xxxxxxxxxxxxxxxx/catalogsearch/result/?q=psc&cat=231&manufacturer=3
Finally it was resulting the empty products list when i enable smile sa modules. Other when using default Magento Search these dropdowns are working fine.
Please suggest is there anything to do to integrate the above code with Smile SA.