HTML中的框架集问题 [英] Frameset Issue in HTML

查看:63
本文介绍了HTML中的框架集问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Hello Mentors,



我在使用框架时遇到了一些HTML问题。

我有一个四帧的框架集。



在Frameset中我给出了行属性为10%,10%,40%,40%



如下:



< frameset id =mainbodyrows =10%,10%,40%,40%border =falseframeBorder = 0frameSpacing =0>

< frame name =topHeadersrc =../ Something.aspxframeBorder =0marginHeight =10noResize =noresize scrolling =noheight =100%>

< frame name =Frame2src =NGTPMainBody.htmframeBorder =0noResize =noresize>

< frame name =Frame3frameBorder =0noResize =noresizescrolling =no>

< frameset id =Frame4cols = 0%,60%,0%border =falseframeBorder =0frameSpacing =0>





现在帧加载很好,但我还有一个要求在水平seper中更改 frame3和frame4 一种方式。



我可以在运行时使用Javascript。请建议!

Hello Mentors,

I am stuck with some HTML issues while working with frames.
I have a frameset with four frames.

In Frameset i have given rows attribute as 10%,10%,40%,40%

as follow:

<frameset id="mainbody" rows="10%,10%,40%,40%" border="false" frameBorder="0" frameSpacing="0">
<frame name="topHeader" src="../Something.aspx" frameBorder="0" marginHeight="10" noResize="noresize" scrolling="no" height="100%">
<frame name="Frame2" src="NGTPMainBody.htm" frameBorder="0" noResize="noresize">
<frame name="Frame3" frameBorder="0" noResize="noresize" scrolling="no">
<frameset id="Frame4" cols="0%,60%,0%" border="false" frameBorder="0" frameSpacing="0">


Now frames are loading great but i have one more requirement to change the frame3 and frame4 in a horizontally seperated way.

Can i do it in Javascript at runtime. Please suggest!

推荐答案

当然你可以用javascript操纵帧(如果你不试图违反同源策略)。请参阅:

http://www.mobilefish.com/tutorials/javascript/javascript_quickguide_framesize .html [ ^ ]

http://javascript.gakaa.com/frame-height-2- 0-width.aspx [ ^ ]



但忘了帧!这是一种非常古老的布局方式。它已在HTML5中弃用。如果可能,请切换到无表格布局
Of course you can manipulate frames with javascript (if you don''t try to violate same-origin policy). See these:
http://www.mobilefish.com/tutorials/javascript/javascript_quickguide_framesize.html[^]
http://javascript.gakaa.com/frame-height-2-0-width.aspx[^]

But forget frames! It is a really old way to make layout. It is deprecated already in HTML5. Switch to table-less layout if possible.


这篇关于HTML中的框架集问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆