jQuery MiniUI
标题:
奇怪的问题:不能撑满页面?
[打印本页]
作者:
sxyzy
时间:
2013-5-23 18:02:48
标题:
奇怪的问题:不能撑满页面?
本帖最后由 sxyzy 于 2013-5-23 18:09 编辑
实验1:显示:[attach]1998[/attach]
代码:
<!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 id="Head1"><title>
角色列表
</title>
<script src="/scripts/boot.js" type="text/javascript"></script>
<style type="text/css">
html, body
{
margin: 0;
padding: 0;
border: 0;
width: 100%;
height: 100%;
overflow: hidden;
}
</style>
</head>
<body>
<form name="form1" method="post" action="RoleList.aspx" id="form1">
<div>
<input type="hidden" name="__VIEWSTATE" id="__VIEWSTATE" value="/wEPDwUKLTM5NTIzODUyMWRkmIcq77XdZeQVq2Vl+FMhgz81kh8=" />
</div>
<div class="mini-toolbar" style="padding: 2px; border-bottom: 0;">
<table style="width: 100%;">
<tr>
<td style="width: 100%;">
<a id="A1" class="mini-button" iconcls="icon-add" onclick="add()">增加</a>
<a id="A2" class="mini-button" iconcls="icon-add" onclick="edit()">编辑</a>
<a id="A3" class="mini-button" iconcls="icon-remove" onclick="remove()">
删除</a>
</td>
<td style="white-space: nowrap;">
<input id="key" class="mini-textbox" emptytext="请输入角色名称" style="width: 150px;" onenter="onKeyEnter" />
<a class="mini-button" onclick="search()">查询</a>
</td>
</tr>
</table>
</div>
<!--撑满页面-->
<div class="mini-fit" style="height: 100%;">
<div id="datagrid1" class="mini-datagrid" style="width: 100%;height: 100%;" allowresize="true"
url="RoleService.aspx?method=SearchRole" idfield="RoleId" multiselect="true">
<div property="columns">
<div type="indexcolumn" width="10%"></div>
<div type="checkcolumn" width="10%">
</div>
<div field="RoleName" width="30%" headeralign="center" allowsort="true">
角色</div>
<div field="RoleRemark" width="50%" headeralign="center" allowsort="true">
角色备注</div>
</div>
</div>
</div>
</form>
<script type="text/javascript">
/////////////////////////////////////////////////
</script>
</body>
</html>
复制代码
实验2:显示[attach]2000[/attach]
代码:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" >
<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1"><title>
角色列表
</title>
<script src="/scripts/boot.js" type="text/javascript"></script>
<style type="text/css">
html, body
{
margin: 0;
padding: 0;
border: 0;
width: 100%;
height: 100%;
overflow: hidden;
}
</style>
</head>
<body>
<form name="form1" method="post" action="RoleList.aspx" id="form1">
<div>
<input type="hidden" name="__VIEWSTATE" id="__VIEWSTATE" value="/wEPDwUKLTM5NTIzODUyMWRkmIcq77XdZeQVq2Vl+FMhgz81kh8=" />
</div>
<div class="mini-toolbar" style="padding: 2px; border-bottom: 0;">
<table style="width: 100%;">
<tr>
<td style="width: 100%;">
<a id="A1" class="mini-button" iconcls="icon-add" onclick="add()">增加</a>
<a id="A2" class="mini-button" iconcls="icon-add" onclick="edit()">编辑</a>
<a id="A3" class="mini-button" iconcls="icon-remove" onclick="remove()">
删除</a>
</td>
<td style="white-space: nowrap;">
<input id="key" class="mini-textbox" emptytext="请输入角色名称" style="width: 150px;" onenter="onKeyEnter" />
<a class="mini-button" onclick="search()">查询</a>
</td>
</tr>
</table>
</div>
<!--撑满页面-->
<div class="mini-fit" style="height: 100%;">
<div id="datagrid1" class="mini-datagrid" style="width: 100%;height: 100%;" allowresize="true"
url="RoleService.aspx?method=SearchRole" idfield="RoleId" multiselect="true">
<div property="columns">
<div type="indexcolumn" width="10%"></div>
<div type="checkcolumn" width="10%">
</div>
<div field="RoleName" width="30%" headeralign="center" allowsort="true">
角色</div>
<div field="RoleRemark" width="50%" headeralign="center" allowsort="true">
角色备注</div>
</div>
</div>
</div>
</form>
<script type="text/javascript">
/////////////////////////////////////////////////
</script>
</body>
</html>
复制代码
作者:
sxyzy
时间:
2013-5-23 18:08:29
两次的变更的是DOCTYPE声明;
第一次不能显示内容,第二次不能显示页脚和字段宽度没有按照要求显示。
asp.net c#
作者:
niko
时间:
2013-5-23 21:53:00
1.头部必须加:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
2.<form style="width:100%;height:100%"
作者:
sxyzy
时间:
2013-5-24 09:38:44
niko 发表于 2013-5-23 21:53
1.头部必须加:
2.
感谢!已解决!
欢迎光临 jQuery MiniUI (http://miniui.com/discuss/)
Powered by Discuz! X2