When i open admin url, I see this error

Fatal error: Call to a member function getUsername() on a non-object in /app/design/adminhtml/default/default/template/page/header.phtml on line 33 Any ideas?

1 Answer 1


if you use customer session than add session condition

$session = Mage::getSingleton('customer/session');
if($session->isLoggedIn()) {

  • can you please share header.phtml filde code here? Commented Feb 3, 2016 at 6:36

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.