Magento - Check if a User is logged in
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");
}
?>
I bow down humbly in the...
I bow down humbly in the presence of such gretanses.
I don't work with that...
I don't work with that framework but I think your source code is wrong... actually you need to swap the 'echo' callings.
Post new comment