Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
litespeed_wiki:cache:litemage:troubleshooting:mirasvit-sear-box-missing [2017/02/22 20:44]
Michael Alegre created
litespeed_wiki:cache:litemage:troubleshooting:mirasvit-sear-box-missing [2017/05/09 12:53] (current)
Lisa Clarke
Line 1: Line 1:
 +~~NOTOC~~
 ====== Mirasvit Search AutoComplete Box Missing After Enabling LiteMage ====== ====== Mirasvit Search AutoComplete Box Missing After Enabling LiteMage ======
  
-If you have added header” in LiteMage'​s **Customized Block Names for "​toplinks"​ Tag** setting ​(could link to that wiki entry), the entire header will be treated as one big ESI block. When LiteMage is enabled, the default search box will show up in the header, but not the customized ​Misrasvit ​search box. +====Problem==== 
- +If you have added ''​header'' ​in LiteMage'​s ​[[litespeed_wiki:​cache:​litemage:​configuration:​user-defined_cache_rules|**Customized Block Names for "​toplinks"​ Tag** setting]], the entire header will be treated as one big ESI block. When LiteMage is enabled, the default search box will show up in the header, but not the customized ​Mirasvit ​search box. 
-  - Locate the layout XML added by Misrasvit search box. In our example this is located in: <​code>​design/​frontend/​base/​default/​layout/​mst_searchautocomplete.xml</​code> ​In the default handle, it adds search.block. <​code><​default>​+====Cause==== 
 +The Mirasvit search block is not directly added to header block in the layout, but is added later in the ''​addSearchAutocomplete''​ action method call. The related code is located in the ''​Mirasvit_SearchAutocomplete_Block_Layout addForm()''​ function in file ''​app/​code/​local/​Mirasvit/​SearchAutocomplete/​Block/​Layout.php''​. When LiteMage renders the ESI block header based on layout, it is not aware of this replaced search box, thus the default search box is used. 
 +====Solution==== 
 +To fix this: 
 +  - Locate the layout XML added by Misrasvit search box. In our example this is located in ''​design/​frontend/​base/​default/​layout/​mst_searchautocomplete.xml''​. \\ \\ In the default handle, it adds search.block. <​code><​default>​
   …   …
         <block type="​searchautocomplete/​layout"​ name="​search.block">​         <block type="​searchautocomplete/​layout"​ name="​search.block">​
Line 10: Line 15:
   …   …
 </​default></​code>​ </​default></​code>​
-     +  ​Add this block to the header block in the layout file, allowing the related layout xml to be picked up by LiteMage. Modify the above layout file, wrapping the block with a header reference. <​code><​default>​
-  ​This search block is not directly added to header block in the layout, but is added later in the ''​addSearchAutocomplete''​ action method call. The related code is located in the ''​Mirasvit_SearchAutocomplete_Block_Layout addForm()''​ function in file ''​app/​code/​local/​Mirasvit/​SearchAutocomplete/​Block/​Layout.php''​. When LiteMage renders the ESI block header based on layout, it is not aware of this replaced search box, thus the default search box is used. +
-  - To fix this, simply add this block to the header block in the layout file, allowing the related layout xml to be picked up by LiteMage. Modify the above layout file, wrapping the block with a header reference. <​code><​default>​+
   …   …
     <​reference name="​header">​     <​reference name="​header">​
Line 22: Line 25:
 </​default>​ </​default>​
 </​code>​ </​code>​
- 
   - Flush the Magento configuration cache and LiteMage cache. The customized search box should now appear as normal.   - Flush the Magento configuration cache and LiteMage cache. The customized search box should now appear as normal.
  • Admin
  • Last modified: 2017/02/22 20:44
  • by Michael Alegre