开发者

How can I make a dropdown inside on iframe drop down on top of the other frames

开发者 https://www.devze.com 2023-02-16 01:15 出处:网络
I have the following in my frameset.jsp </head> <iframe width=\"100%\" src=\"mail_frame.html\"></iframe>

I have the following in my frameset.jsp

</head>

       <iframe width="100%" src="mail_frame.html"></iframe>

       <iframe width="105开发者_StackOverflow中文版px" height="100%" src="sidenav.html" id="leftnav" name="leftnav" ></iframe>

       <iframe height="100%" src="body.htm" id="main" name="main"></iframe>


</html>

How can I make a drop down contained in mail_frame.html drop down and and overlap the other two frames below it?


You can't. Frame content is contained within the frame and cannot be positioned outside of it.

It could be faked with cross-frame Javascript that triggers displaying the dropdown in another frame, but that is a hack and will result in headaches.

You are probably better off by not using frames, which is easy if you use some kind of server-side script that includes mail_frame.html, sidenav.html and body.html in one page.

It would look something like this in PHP: (you'll have to adjust it a bit for yourself to make it work)

</head>

       <div id="mail_frame"><?php include('mail_frame.html'); ?></div>

       <div id="leftnav"><?php include('sidenav.html'); ?></div>

       <div id="main"><?php include('body.html'); ?></div>

</html>
0

精彩评论

暂无评论...
验证码 换一张
取 消