Magento判断用户是否已经登录
You may want to check if a user is logged in with Magento, possibly to display a link or promotional item. Here’s how to do it:
<?php
if ($this->helper('customer')->isLoggedIn()) {
echo("Anonymous user");
}
else {
echo("Authenticated user");
}
?>
阅读其他美文