增加一个content-body样式,适配前台配置的页面到iframe中

This commit is contained in:
Argo-Lenovo 2016-11-01 20:14:27 +08:00
parent ce5118ef53
commit 297b7f511f
5 changed files with 25 additions and 6 deletions

View File

@ -133,4 +133,20 @@
top: 94px; top: 94px;
overflow: auto; overflow: auto;
} }
.content-body {
position: fixed;
left: 0;
bottom: 40px;
right: 0;
top: 94px;
overflow: hidden;
}
.content-body iframe {
width: 100%;
border: none;
height: 100%;
overflow: auto;
}
} }

View File

@ -628,8 +628,7 @@ ul.breadcrumb {
padding-right: 6px; padding-right: 6px;
} }
iframe { .content-body iframe {
width: 100%; width: 100%;
border: none; border: none;
height: 500px;
} }

View File

@ -9,7 +9,7 @@
<title></title> <title></title>
</head> </head>
<body> <body>
<div style="height: 1000px; background-color: aqua">我就是一个测试页面</div> <div style="height: 1000px; background-color: #77af77">我就是一个测试页面</div>
<div>Bottom</div> <div>Bottom</div>
</body> </body>
</html> </html>

View File

@ -1 +1,4 @@
 $(function () {
var fra = $('iframe').get(0);
fra.height = fra.contentDocument.body.offsetHeight;
});

View File

@ -1,3 +1,4 @@
@model ContentModel @model ContentModel
<h4>欢迎使用本系统</h4> <div class="content-body">
<iframe id="fraContent" src="@Model.Url"></iframe> <iframe src="@Model.Url"></iframe>
</div>