先用框架查询
namespace Home\Controller;use Home\Controller\FuLeiController;
class WccController extends FuLeiController
{//查看项目的方法function xiangmu(){$xiangmu=D("xiangmu");$zhi=$xiangmu->select();$this->assign("zhi",$zhi);$this->display();}
}
然后显示页面,内容用弹窗的形式弹出
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>无标题文档</title>
<script src="/JiaoWu/JiaoWu/A/Public/four/llx/js/jquery-1.11.2.min.js"></script>
<script src="/JiaoWu/JiaoWu/A/Public/four/llx/js/tanchuang.js"></script><style type="text/css">
@import url("/JiaoWu/JiaoWu/A/Public/four/llx/css/tanchuang.css");
</style>
</head><body>
<table width="100%" border="1" cellpadding="0" cellspacing="0">
<tr>
<td>项目名称</td>
<td>上传人</td>
<td>开始时间</td>
<td>结束时间</td>
<td>评分</td>
<td>操作</td>
</tr>
<foreach name="zhi" item="v">
<tr>
<td><{$v.name}></td>
<td><{$v.owner}></td>
<td><{$v.starttime}></td>
<td><{$v.endtime}></td>
<td><{$v.level}></td>
<td><span class="neirong" nr="<{$v['content']}>">查看详情</span></td>
</tr>
</foreach>
</table>
</body>
</html>
<script type="text/javascript">
$(document).ready(function(e) {$(".neirong").click(function(){var html = "<div style='color:red'>这是测试的弹窗</div>";var button ="<input type='button' value='确定' /><input type='button' value='取消' />";var neirong = $(this).attr("nr");var win = new Window({width : 700, //宽度height : 500, //高度title : '项目内容', //标题content : neirong, //内容isMask : false, //是否遮罩buttons : button, //按钮isDrag:true,});})
});
</script>