*/ class Mage_Contacts_Helper_Data extends Mage_Core_Helper_Abstract { const XML_PATH_ENABLED = 'contacts/contacts/enabled'; public function isEnabled() { return Mage::getStoreConfig( self::XML_PATH_ENABLED ); } public function getUserName() { if (!Mage::getSingleton('customer/session')->isLoggedIn()) { return ''; } $customer = Mage::getSingleton('customer/session')->getCustomer(); return trim($customer->getName()); } public function getUserEmail() { if (!Mage::getSingleton('customer/session')->isLoggedIn()) { return ''; } $customer = Mage::getSingleton('customer/session')->getCustomer(); return $customer->getEmail(); } }