how can I hide messages after certain time. I'm using a custom model.
$redirectMsg = Mage::getSingleton('customer/session')->addSuccess('hii');
Magento Stack Exchange is a question and answer site for users of the Magento e-Commerce platform. It only takes a minute to sign up.
Sign up to join this communityhow can I hide messages after certain time. I'm using a custom model.
$redirectMsg = Mage::getSingleton('customer/session')->addSuccess('hii');
To add your js
code in all pages, let's do it as well as it should.
First, you have to create a new js file, then you declare this js
file because Magento doesn't know it yet.
js
:app/design/frontend/{your_package_theme}/{your_theme_name}/layout/local.xml
<?xml version="1.0"?>
<layout version="0.1.0">
<default>
<reference name="head">
<action method="addItem"><type>skin_js</type><name>js/glob-messages.js</name></action>
</reference>
</default>
</layout>
glob-messages.js
file : skin/frontend/{your_package_theme}/{your_theme_name}/js/glob-messages.js
/*Your js code goes here...*/
Flush cache, then your code is in place.
js