求助:一个关于thinkphp框架下页面分帧的问题

qq_35041101 2016-07-12 07:41:27
在thinkphp框架下做页面分帧,但是没有显示出预想的效果。
代码如下:
前台页面(tpl文件夹下的文件):
主文件
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<title>index</title>
</head>
<frameset rows='20%,80%'>
<frame src='__URL__/top' name='top'/>
<frameset cols='50%,50%'>
<frame src='__URL__/left' name='left'/>
<frame src='__URL__/right' name='right'/>
</frameset>
</frameset>
</html>

<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<title>Right</title>
</head>
<body>
top
</body>
</html>

上左右的分帧页面写法一样
后台文件(Action文件夹中)
<?php
class CashAction extends Action{
public function cash()
{
echo "this cash";
$this->display();
}

public function top()
{
echo 'this is top\n';
$this->dispaly();
}
public function left()
{
echo 'this is left\n';
$this->dispaly();
}
public function right()
{
echo 'this is right\n';
$this->dispaly();
}
}
?>

模块的名称叫cash
但是现在只在浏览器中显示this is cash,没有其他几个函数中的输出语句,也没有分帧效果
显示的文件流程如下:
1.F:\wamp\www\fm\index.php ( 0.20 KB )
2.F:\wamp\www\fm\ThinkPHP\ThinkPHP.php ( 1.53 KB )
3.F:\wamp\www\fm\ThinkPHP\Common\runtime.php ( 9.72 KB )
4.F:\wamp\www\fm\ThinkPHP\Common\common.php ( 19.37 KB )
5.F:\wamp\www\fm\ThinkPHP\Lib\Core\Think.class.php ( 10.62 KB )
6.F:\wamp\www\fm\ThinkPHP\Lib\Core\ThinkException.class.php ( 3.32 KB )
7.F:\wamp\www\fm\ThinkPHP\Lib\Core\Behavior.class.php ( 1.71 KB )
8.F:\wamp\www\fm\ThinkPHP\Conf\alias.php ( 1.15 KB )
9.F:\wamp\www\fm\ThinkPHP\Conf\convention.php ( 9.01 KB )
10.F:\wamp\www\fm\Home\Conf\config.php ( 0.30 KB )
11.F:\wamp\www\fm\ThinkPHP\Lang\zh-cn.php ( 2.59 KB )
12.F:\wamp\www\fm\ThinkPHP\Conf\tags.php ( 1.56 KB )
13.F:\wamp\www\fm\ThinkPHP\Common\functions.php ( 26.00 KB )
14.F:\wamp\www\fm\ThinkPHP\Lib\Core\Log.class.php ( 4.69 KB )
15.F:\wamp\www\fm\ThinkPHP\Lib\Core\Dispatcher.class.php ( 10.63 KB )
16.F:\wamp\www\fm\ThinkPHP\Lib\Core\App.class.php ( 13.95 KB )
17.F:\wamp\www\fm\ThinkPHP\Lib\Core\Action.class.php ( 15.57 KB )
18.F:\wamp\www\fm\ThinkPHP\Lib\Core\View.class.php ( 4.39 KB )
19.F:\wamp\www\fm\ThinkPHP\Conf\debug.php ( 1.73 KB )
20.F:\wamp\www\fm\ThinkPHP\Lib\Behavior\CheckRouteBehavior.class.php ( 9.01 KB )
21.F:\wamp\www\fm\ThinkPHP\Lib\Behavior\ReadHtmlCacheBehavior.class.php ( 5.48 KB )
22.F:\wamp\www\fm\Home\Lib\Action\CashAction.class.php ( 0.38 KB )
23.F:\wamp\www\fm\ThinkPHP\Lib\Behavior\LocationTemplateBehavior.class.php ( 2.22 KB )
24.F:\wamp\www\fm\ThinkPHP\Lib\Behavior\ParseTemplateBehavior.class.php ( 5.90 KB )
25.F:\wamp\www\fm\ThinkPHP\Lib\Template\ThinkTemplate.class.php ( 27.89 KB )
26.F:\wamp\www\fm\ThinkPHP\Lib\Driver\TagLib\TagLibCx.class.php ( 24.35 KB )
27.F:\wamp\www\fm\ThinkPHP\Lib\Template\TagLib.class.php ( 8.55 KB )
28.F:\wamp\www\fm\Home\Runtime\Cache\1dfa0724ff8cd4502caf47e8de650d25.php ( 0.39 KB )
29.F:\wamp\www\fm\ThinkPHP\Lib\Behavior\ContentReplaceBehavior.class.php ( 2.29 KB )
30.F:\wamp\www\fm\ThinkPHP\Lib\Behavior\TokenBuildBehavior.class.php ( 2.51 KB )
31.F:\wamp\www\fm\ThinkPHP\Lib\Behavior\WriteHtmlCacheBehavior.class.php ( 1.41 KB )
32.F:\wamp\www\fm\ThinkPHP\Lib\Behavior\ShowRuntimeBehavior.class.php ( 3.59 KB )
33.F:\wamp\www\fm\ThinkPHP\Lib\Behavior\ShowPageTraceBehavior.class.php ( 5.44 KB )

请问这个问题可能出在哪里呢?很急,在线等,谢谢
...全文
198 2 打赏 收藏 转发到动态 举报
写回复
用AI写文章
2 条回复
切换为时间正序
请发表友善的回复…
发表回复
xuzuning 2016-07-13
  • 打赏
  • 举报
回复
tp 的 url 格式是 域名/模块名/方法名 你写成 src='__URL__/top' 显然是不对的! 你并没有 TopAction 控制器
qq_35041101 2016-07-12
  • 打赏
  • 举报
回复
action中的代码 $this->dispaly(); 是笔误,换成正确写法试了还是不行

4,251

社区成员

发帖
与我相关
我的任务
社区描述
国内外优秀PHP框架讨论学习
社区管理员
  • Framework
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧