magento-管理员登录后打开弹出窗口
我想在管理员成功登录时显示弹出窗口。我有一个带有config.xml文件的自定义模块magento-管理员登录后打开弹出窗口,magento,Magento,我想在管理员成功登录时显示弹出窗口。我有一个带有config.xml文件的自定义模块Setstore_Notification- <config> <modules> <Setstore_Notification> <version>0.0.1</version> </Setstore_Notification> </modules> <global>
Setstore_Notification
-
<config>
<modules>
<Setstore_Notification>
<version>0.0.1</version>
</Setstore_Notification>
</modules>
<global>
<events>
<admin_session_user_login_success>
<observers>
<Setstore_Notification_customer_register_success>
<type>singleton</type>
<class>Setstore_Notification_Model_Observer</class>
<method>choosestore</method>
</Setstore_Notification_customer_register_success>
</observers>
</admin_session_user_login_success>
</events>
</global>
</config>
0.0.1
独生子女
设置存储通知模式观察者
精品店
和模型中的观察者文件-
<?php
class Setstore_Notification_Model_Observer {
public function choosestore(Varien_Event_Observer $observer) {
$event = $observer->getEvent();
$layout = $observer->getEvent()->getLayout();
-----
}
}
?>
我不明白如何调用observer文件中的弹出窗口。我在仪表板页面中包含了window.js
感谢您的帮助
谢谢。通过渲染块来完成
$this->loadLayout();
$layout = $this->getLayout();
$block = $layout->getBlock("hello");
echo $block->toHtml();
在hello街区内
<script>doPopup();</script>
echo $this->getLayout()->createBlock('cms/block')
->setBlockId('idOfMyCmsPage')
->toHtml();