View Full Version : Div/Iframe problems
kimikai
04-13-2012, 10:31 PM
I'm trying to make a site which basically has 2 divs placed next to each other, like a small one on the left for the menu, and a bigger one on the right for the content. Now because the menu is quite a complex one, and its not easy at all to figure out the whole code and put that in the main page, i figured id put that on a diff. webpage, make an iframe in the menu div, and display it like that. Also because my website wasnt build for long scrolling pages, i decided to put another iframe in the content div. The problem im facing now is that it places the content div underneith the menu div, although it does read the margin i set. Now ive tried a testsite with the same build, just no iframes in it, and that works fine. In the CSS coding ive tried floating and z-index, both didnt work. Any1 knows how to fix this, OR how i can display the menu in the div w/o using an iframe (maybe thatll solve it) OR what the proper code is to put an iframe into a div so IE reads it.
keyboard
04-14-2012, 11:10 AM
Please post a link to the page on your site that contains the problematic script so we can check it out.
or
Please post the problamatic code so we can check it out.
kimikai
04-14-2012, 02:18 PM
The HTML code:
<div id="main_wrap">
<div id="site_wrap">
<div id="menu_wrap">
<iframe name="menu" src="menu.html" frameborder="0" width="160px" height="404px" allowtransparency="true" scrolling="no"></iframe>
<div id="content_wrap">
<iframe name="content" src="home.html" frameborder="0" width="753px" height="403px" allowtransparency="true" scrolling="auto"></iframe>
</div>
</div>
</div>
</div>
The CSS part:
#main_wrap {
width:100%;
height:437px;
margin:0;
background:url(images/rest_bg.jpg);
}
#site_wrap {
width:960px;
height:437px;
margin:0 auto;
background:url(images/rest_bg.jpg);
}
#menu_wrap {
width:165px;
height:408px;
margin-left:15px;
background:url(images/menu_bg.jpg);
}
#content_wrap {
width:758px;
height:407px;
margin-left:175px;
background:url(images/content_bg.jpg);
}
I myself came as far as to realise when i leave out the iframes, it does work good, so the problems come in when i add the Iframes into the divs.
kimikai
04-17-2012, 07:28 AM
any1 knows how to fix this?? plz!! i really need a solution
#update: fixed =3 it all works fine now
molendijk
04-17-2012, 09:58 PM
You are probably looking for something like this (http://mesdomaines.nu/eendracht/include_menu_web_templates4).
===
Arie Molendijk.
Powered by vBulletin® Version 4.2.2 Copyright © 2021 vBulletin Solutions, Inc. All rights reserved.