473,748 Members | 9,596 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

I'm having trouble displaying two iframes side-by-side.

Screaming Eagle
4 New Member
Ok, so some associates and I are building a website, and I'm in charge of the design and layout. I've decided to go with a simple navigation bar on top contained in its own div. Under the navigation bar, I have two iframes contained in one div and each iframe in its own inside the container div. In theory it was supposed to have shown the user statistics to the left at a width of 160 pixels and lowered from the top at 73 pixels. That displays fine.

Where everything falls apart is when the second iframe: "iframemain " (which should show up right next to the first) appears beneaththe user statistics iframe, and at the same dimentions as the user statistics iframe; I simply want it to take up the rest of the screen with my "iframemain ".

This problem seems to happen on both IE6 and Firefox

I have tried not having a container div around both; I've removed the html height/width elements that I had previously placed in the body of the code; I've played around with height and width in the CSS coding as well; I taken away absolute postions, and as you can see, I've made the user div inline. I'm pretty much stumped as to what I'm missing here. Can anyone give me a pointer?

This is my CSS code:

Expand|Select|Wrap|Line Numbers
  1. body {font-size:8pt}
  2.  
  3. hr  {color:black}
  4.  
  5. p.img {font:8pt; color:black}
  6.  
  7. a.reg:link,a.reg:visited,a.reg:active       {font:6pt; color:black; text-decoration:none}
  8. a.reg:hover     {font:6pt; color:black; text-decoration:underline}
  9.  
  10. th,tr,td   {color:black; font-size:8pt}
  11.  
  12. table.one   {table-layout:auto; border-collapse:separate;
  13.     empty-cells:show; border-color:white;
  14.     border-style:none; padding:0; margin:0}
  15.  
  16. div.main {float:left; border:1px; overflow:hidden;
  17.     left:0px; top:0px; padding:0; margin:0}
  18.  
  19. div.wb1 {float:left; background-color:white; 
  20.     width:325px; height:390px; z-index:0}
  21.  
  22. div.background  {float:left; left:0px; top:0px;
  23.     padding:0; z-index:-1}
  24.  
  25. div.nav {float:left; height:70px; border:1px; border:solid; 
  26.     border:black; left:1px; top:1px; padding:0}
  27.  
  28. div.contain {float:left; width:100%; padding:0; margin:0}    
  29.  
  30. div.user {float:left; width:160px; 
  31.     border:1px; border:solid; border:black;
  32.     left:1px; top:73px; padding:0; display:inline}
  33.  
  34. div.iframemain {float:left; top:73px; left:163px;
  35.     padding:0}
  36.  
  37. img.background1  {left:0px; top:0px; z-index:-1}
  38.  
  39. img.background2 {margin-left:20%}
  40.  
This is my xhtml code:

Expand|Select|Wrap|Line Numbers
  1. <div class="nav">
  2.       <!-- THE NAVBAR!-->
  3.       <table class="one" style="margin-left:350px" cellpadding="5">
  4.         <tr>
  5.           <td><a class="reg" href="nav1.htm" target="actframe">Nav choice1</a></td>
  6.           <td><a class="reg" href="area.htm" target="actframe">Nav choice2</a></td>
  7.           <td><a class="reg" href="nav2.htm" target="actframe">Nav choice3</a></td>
  8.           <td><a class="reg" href="nav3.htm" target="actframe">Nav choice4</a></td>
  9.           <td><a class="reg" href="nav4.htm" target="actframe">Nav choice5</a></td>
  10.           <td><a class="reg" href="nav5.htm" target="actframe">Nav choice6</a></td>
  11.         </tr>
  12.         <tr>
  13.           <td><a class="reg" href="nav6.php" target="actframe">Nav choice6</a></td>
  14.           <td><a class="reg" href="nav7.htm" target="actframe">Nav choicel8</a></td>
  15.           <td><a class="reg" href="nav8.htm" target="actframe">Nav choice9</a></td>
  16.           <td><a class="reg" href="http://www.mywebsite.net/forums/" target="_blank">Forums</a></td>
  17.           <td><a class="reg" href="bugreport.htm" target="actframe">Bug Report</a></td>
  18.           <?php
  19.  
  20.           if($usertype == "Admin")
  21.           {
  22.           echo "<td><a class=\"reg\" href=\"admin.php\" target=\"actframe\">Admin</a></td>";
  23.           }
  24.  
  25.           ?>
  26.         </tr>
  27.       </table>
  28.     </div>
  29.  
  30.     <div class="contain">
  31.  
  32.       <div class="user">
  33.         <!--this contains a separate page on the left of the screen for user statistics-->
  34.         <iframe src="user.php" name="showframe" frameborder="0" />
  35.       </div>
  36.  
  37.       <div class="iframemain">
  38.         <!--this is where the user should see all of the links appear when clicked-->
  39.         <iframe src="area.htm" name="actframe" frameborder="0" />
  40.       </div>
  41.  
  42.  
  43.     </div>
  44.  
  45.   </body>
  46.  
  47.   <frameset>
  48.     <frame src="area.htm" name="actframe"/>
  49.   </frameset>
  50.  
Aug 31 '07 #1
0 3150

Sign in to post your reply or Sign up for a free account.

Similar topics

10
3934
by: maxim vexler | last post by:
I'm reading a lot of talks lately about the term iFrame and with your permission would like to ask a few question about that : - what is iFrame, i mean what is it good for ? - does all the popular browsers support it (mostly mozilla & the much hated IE, google says the do but nothing is better that experienced answer) - iFrames replaces the old frames once used in html to show a number of pages in a single windows, right ? - what are...
0
2099
by: Dan Popa | last post by:
Check out the following 2 links: http://www.batisdev.com/admin/test_1images.asp http://www.batisdev.com/admin/test_2images.asp First page contain 4 IFRAMES and 1 IMG tags. Second page contain 4 IFRAMES and 2 IMGs tags. The problem is that the second IFRAME from the second page generates fires a new session.
1
1682
by: Nick Tew | last post by:
Hello, This relates to the previous post i've left. This problem is do with the browser's back and forward buttons. When clicked, can it be made to affect any history NOT in the iframes. Therefore only going backwards and forwards through the pages history; leaving the iframes as they are. Any help would be great.
4
2697
by: Arne Hendrickson | last post by:
Can anyone tell me how to edit this script for "traditional frames" to work with iframes? SCRIPT language="JavaScript"> <!----hide function change2() { parent.left_frame.location="page3.htm"; parent.right_frame.location="page4.htm"; }
0
1331
by: fleemo17 | last post by:
IE5 (5.2.3) for the Mac seems to be having problems displaying page elements using Position attributes. If I place the position of my form box (shown at http://tinyurl.com/cz5xd ) using "absolute," the CSS drop-down menus no longer function. If I position it using "relative," the drop-downs function ok, but the form's input box and submit button disappear! Complete chaos. The page works fine in IE6, Firefox, Netscape 7.1 on the PC and...
2
2095
by: Guadala Harry | last post by:
1. Are IFrames supported only in uplevel versions of IE? If not IE exclusively, what browsers support IFrames? 2. Are IFrames going to be supported in the future - as far as anyone knows - or have they been deprecated and will no longer be supported in the future? Please note that I'm *not* asking for opinions on the merits of using IFrames or IFrames vs regular framesets or any other such...
7
1231
by: Adrian Parker | last post by:
Having a problem with validators. Because we want to only test whether the current field in a changed event is valid before we process the change code, I have tried to turn off all validators for the page (all ctrls are in a table), then just enable the one relevant validator, run the page.validate and then if valid, do the change code. otherwise, skip the change code and then finally enable all the validators again. What's happening...
4
3848
by: sanjnair | last post by:
I have a page which has 3 iframes- top frame , left frame and middle frame. The middle frame has text fields for users to enter information into. Now when the autocomplete option is set on the browser, the drop down box appears around 50 to 100 pixels below the text , and not just below the text box as it should be. Anybody knows how to fix the problem? I see that this problem only happens when i Use Iframes, as i tried the typing in text...
2
12891
by: ericisjusteric | last post by:
I have a page with multiple iframes and need to have the user (ie6) be able to click a button to refresh any one of the iframes - but also to click another button at the top of the page to refresh all of them - from the server (this could be on page refresh also) as the purpose is to reset the iframe to the original content in case the user clicked on a link in that iframe and changed it, but also in case there were updates to the original page...
1
1510
by: jeddiki | last post by:
Hi, I am having difficulty seeing why my divs will not swap places :confused: I want to swap the positions of the "Hot News" and the "Todays Bonuese" sections. Here is how they look now: http://www.expert-world.com/im/images/trash1.jpg
0
8991
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8830
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
1
9321
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
1
6796
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6074
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4602
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4874
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3312
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
2782
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.