Differences

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

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
litespeed_wiki:cache:litemage:troubleshooting:logged-in-user-info-shown-to-others [2017/05/03 13:07]
Michael Alegre Improved format.
litespeed_wiki:cache:litemage:troubleshooting:logged-in-user-info-shown-to-others [2018/06/26 14:16] (current)
Jackson Zhang [Solution]
Line 1: Line 1:
 +~~NOTOC~~
 ====== Logged In Usernames/​Cart Items Shown On Other User's Pages ====== ====== Logged In Usernames/​Cart Items Shown On Other User's Pages ======
- +==== Symptoms ​====
-**Symptoms:**+
   * Logged in Usernames/​Cart Items being shown on other user's pages. (seen in Ultimo Theme, Meigee Harbour Theme)   * Logged in Usernames/​Cart Items being shown on other user's pages. (seen in Ultimo Theme, Meigee Harbour Theme)
   * Shopping cart item count wrong.   * Shopping cart item count wrong.
  
-**Cause**: The block containing username is not being hole-punched properly, and causes private information to be publicly cached and displayed on public pages or other user'pages.  +==== Cause ==== 
- +The block containing username/shopping cart is not being hole-punched properly, and causes private information to be publicly cached and displayed on public pages or other users' pages. ​
-To confirm that this is the problem, you can enable debug mode and append **?​LITEMAGE_DEBUG=SHOWHOLES** to the end of your site URL. This will show all holes being punched on the page, where you can check if the block containing the username or cart items is being punched properly.+
  
-**Solution**:​ The simplest solution to this problem ​is to go to the Magento Admin Panel and navigate ​to System -> Configuration -> LiteMage Configuration and add "​header"​ to **Customized Block Names for "​toplinks"​ Tag**. This will punch one big hole for the entire header ​block.+To confirm that this is the problem, you can enable debug mode and append ''?​LITEMAGE_DEBUG=SHOWHOLES'' ​to the end of your site URL. This will show all holes being punched on the page, where you can check if the block containing the username or cart items is being punched properly.
  
-**Alternate Solution**: The more complicated solution involves looking carefully at your template file for customized codesuch as +==== Solution ==== 
 +The simplest solution to this problem is to go to the Magento Admin Panel and navigate to **System -> Configuration -> LiteMage Configuration** and add ''​header''​ to **Customized Block Names for "​toplinks"​ Tag**. This will punch one big hole for the entire header block. Please be aware that it is only a possible fix and it may or may not work.  If it doesn'​t work or breaks somethingyou should reverse this change back.
  
 +==== Alternate Solution ====
 +A more complicated solution involves looking carefully at your template file for customized code, such as:
 <​code>​ <​code>​
 <?php if($toplinks['​displayas'​] == 1){echo '<​span class="​simple">';​} <?php if($toplinks['​displayas'​] == 1){echo '<​span class="​simple">';​}
Line 21: Line 23:
 </​code>​ </​code>​
  
-Since LiteMage can only punch a hole on a block defined through a layout file, the dynamically generated content here will not be recognized. You can however create a new block containing this logic and define that block in the layout file with a unique name. Once you have done this you can then add this new block name to the **Customized Block Names for "​toplinks"​ Tag** list.+Since LiteMage can only punch a hole on a block defined through a layout file, the dynamically generated content here will not be recognized. You canhowevercreate a new block containing this logic and define that block in the layout file with a unique name. Once you have done this you can then add this new block name to the **Customized Block Names for "​toplinks"​ Tag** list.
  
  • Admin
  • Last modified: 2017/05/03 13:07
  • by Michael Alegre