Zend Framework筆記

1.

if($this->_request->isPost()) 只返回 boolean
if(strtolower($_SERVER['REQUEST_METHOD']) == 'post')) 有可能拋出異常

 

2.

session存儲xml對象:轉換爲一般對象或者數組存放。
The only solution seems to be to copy all
relevant data to a "normal" object or array. Or store any modifications
to the XML source in the XML file.

 

3.

禁用Layout:
$this->_helper->layout->disableLayout();
渲染不同的Layout:
$this->_helper->layout->setLayout(’layout');
layout: Layout文件名(不包含後綴)

發佈了51 篇原創文章 · 獲贊 3 · 訪問量 10萬+
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章