This is an old revision of the document!


Logged In Usernames/Cart Items Shown On Other User's Pages

Problem: Logged in Usernames/Cart Items being shown on other user's pages, seen in Ultimo Theme, Meigee Harbour Theme.

Other Symptoms: 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's 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.

Alter Solution: The more complicated solution involves looking carefully at your template file for customized code, such as

<?php if($toplinks['displayas'] == 1){echo '<span class="simple">';}
if (Mage::getSingleton('customer/session')->isLoggedIn()==1):
echo '<span class="customer-name"><strong>' . $customer->getCustomer()->getName() . '</strong></
span>';
endif;

Since LiteMage con 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.

  • Admin
  • Last modified: 2017/05/03 13:03
  • by Michael Alegre