|
html的frameset標簽在多窗口程序設(shè)計中有著廣泛的應(yīng)用,尤其是在項目后臺頁面部分。本文就來分析Thinkphp后臺首頁index使用frameset時的注意事項。具體如下:
文件路徑:aoli/admin/Lib/Action/IndexAction.class.php
代碼如下:
<?php class IndexAction extends Action{ public function index(){ $this->display(); } public function top(){ $this->display(); } public function left(){ $this->display(); } public function right(){ $this->display(); } }?>
文件路徑:aoli/admin/Tpl/default/Index
index.html頁面代碼如下:
<frameset rows="20%,*"> <frame src="__URL__/top" name="top"> <frameset cols="20%,*"> <frame src="__URL__/left" name="left"> <frame src="__URL__/right" name="right"> </frameset> </frameset>
top.html(略)
left.html(略)
right.html(略)
注意事項:
調(diào)用top.html,left.html,right.html的時候應(yīng)該用路徑__URL__/來調(diào)用方法,而不能用__TMPL__/Index/來調(diào)用模板。
感興趣的讀者可以調(diào)試運行本文示例,體會路徑調(diào)用的具體用法。
php技術(shù):ThinkPHP后臺首頁index使用frameset時的注意事項分析,轉(zhuǎn)載需保留來源!
鄭重聲明:本文版權(quán)歸原作者所有,轉(zhuǎn)載文章僅為傳播更多信息之目的,如作者信息標記有誤,請第一時間聯(lián)系我們修改或刪除,多謝。