Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

fixed and absolute layout not working in IE6

Posted on 2009-04-14
2
849 Views
Last Modified: 2013-12-08
Hi Experts,

I have a simple page layout with a menu spanning the width of the page at the top. I need this to be fixed in place along with the footer fixed also.
I have got the layout pixel perfect in FF 3, Safari Mac and IE7, 8 FF 3. However i come to look at it in the dreaded IE6 and it's completely spannered! I can't see what I have done to make it so out of whack.
Please advise on what I should do!

My URL:

http://www.randomlychallenged.com/HomeTEST.php

I have also attached the MainHeader HTML and the two css style sheets (one for the nav bar one for the main styling)

Thanks for any advise.
///////////////MainHeader
 
<div style="position:fixed; top:0px; left:0px; z-index:10; width:100%; background-image:url(Images/Home/MainBG.jpg); background-repeat:repeat-x;"><div style="width:100%; position:absolute; height:70px; background-image:url(Images/Home/MainBG.jpg); background-repeat:repeat-x;"><div style="width:120px; height:110px; position:absolute; top:0px; left:0px; z-index:500; "><a href="./Home.php" title="Home"><img src="./Images/Home/Home_Logo.jpg" alt="RandomlyChallenged" width="125" height="104" border="0"   longdesc="http://www.randomlychallenged.com/Home.php" /></a></div>
</div>
<div style=" position:absolute; top:70px; left:900px; width:100%; height:30px; background: url(../Images/NavBG.png) repeat-x; border-bottom:#CCCCCC thin solid;  border-top:#CCCCCC thin solid;"></div>
<?php
if (isset($_SESSION['herecomethepain'])) {
?>	
<div class="staticHeader"><div style="position:absolute; top:0; left:200px;"><div>
 
      
	  <object id="swfplaceholder" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="700" height="70">
          <param name="movie"  value="/HeaderTEST.swf"  />
        <!--[if !IE]>-->
        <object type="application/x-shockwave-flash" data="/HeaderTEST.swf" width="700" height="70" style="z-index:10;">
		
        <!--<![endif]-->
         <div><a href="http://www.adobe.com/downloads"><img src="./Images/Home/SignUp.jpg" alt="Join Randomly Challenged - The home of adventure online" width="700" height="118" border="0" /></a></div>
        <!--[if !IE]>-->
        </object>
        <!--<![endif]-->
      </object>
    </div>
  
</div>
 
<div class="chromestyle" id="chromemenu">
 
<ul>
<li class="bodyTxtSmallWhite" style="margin:0 23em 0 0;">Hi<?php if ($newcontentglitch==1) { ?><?php echo $_SESSION['herecomethepain']; ?><?php } else { ?><a href="./MyProfile.php"><?php echo $_SESSION['herecomethepain']; ?></a><?php } ?><br />
Total&nbsp;Experience&nbsp;
<?php echo $exp; ?></li>
<li><a href="http://www.randomlychallenged.com">Home</a></li>
<li><a href="./NewContent.php">New Content</a></li>
<li><a href="./MyProfile.php" rel="dropmenu1">Profile</a></li>
<li><a href="./MyMail.php"  title="You have <?php echo $_SESSION['newmailcount']; ?> new messages">Mail - <?php echo $_SESSION['newmailcount']; ?></a></li>	
<li><a href="#" rel="dropmenu2">Help</a></li>
<li><a href="./Logout_Script.php">Logout</a></li>
 
</ul>
 
</div>
 
<!--1st drop down menu -->                                                   
<div id="dropmenu1" class="dropmenudiv">
<a href="./MyChallenges.php">Challenges</a>
<a href="./MyProfile.php#Friends">Friends</a>
<a href="./MyTrophies.php" title="Total trophies in your cabinet">Trophies - <?php echo $_SESSION['trophies']; ?></a>
 
</div>
 
 
 
<!--3rd drop down menu -->                                                   
<div id="dropmenu2" class="dropmenudiv" style="width: 150px;">
<a href="./FAQ.php.php">FAQ's</a>
<a href="./SiteMap.php">Site Map</a>
<a href="./ContactUs.php">Contact us</a>
</div>
 
</div>
 
</div>
<?php
}
else {
?><div class="bodyTxtBlue" style="background-image:url(Images/Home/LogoutHeader.jpg); background-repeat:no-repeat; height:70px; width:700px; padding:20px 0 0 250px; position:absolute; top:0; left:167px;"><a href="./Registration.php">New to Randomly Challenge?<br />
Take a tour</a></div>
 
<div class="chromestyle" id="chromemenu">
 
<ul>
<li><form action="./Login_Script.php"   method="post"  id="user-login-form"></li>
<li><input name="Username"  type="text"  id="Username" value="Username" size="12" onfocus="if(this.value=='Username') this.value=''" /></li>
    
<li><input name="Password"   type="password"  id="Password" onfocus="if(this.value=='aaaaaaaa') this.value=''"   value="aaaaaaaa"  size="12" />
</li>
          
<li><input name="Submit" type="image" class="bodyTxtSmallWhite" style="margin:0 30.5em 0 0;"   onclick="./Login_Script.php" value="Login"  /></li>
<li></form></li>
<li><a href="http://www.randomlychallenged.com">Home</a></li>
<li><a href="./NewContent.php">New Content</a></li>
<li><a href="#" rel="dropmenu1">Help</a></li>
 
</ul>
</div>
 
 
 
 
<!--1st drop down menu -->                                                   
<div id="dropmenu1" class="dropmenudiv" style="width: 150px;">
<a href="./FAQ.php.php">FAQ's</a>
<a href="./SiteMap.php">Site Map</a>
<a href="./ContactUs.php">Contact us</a>
<a href='#'  onclick="GB_showCenter('Reset Your Password', '../../../PasswordReset_modal.php')">Lost your password?</a>
</div>
 
 
 
 
<?php 
}
?></div>
</div>
<script type="text/javascript">
cssdropdown.startchrome("chromemenu")
</script>
 
 
 
 
/////////////////////////Nav CSS
 
.chromestyle{
width: 100%;
clear:left;
}
 
 
 
.chromestyle ul{
position:absolute;
top:70px;
border-top: thin solid #CCCCCC;
border-bottom: thin solid #CCCCCC;
border-left:none;
border-right:none;
width: 900px;
background: url(../Images/NavBG.png) repeat-x; /*THEME CHANGE HERE*/
padding:3px 0 0 5px;
margin: 0;
height:27px;
text-align:left; /*set value to "left", "center", or "right"*/
font-family: "Lucida Grande" ,"Verdana", "Trebuchet";
font-size: 10px;
color: #2D4D79;
z-index:50;
margin:0 0 0 125px;
}
 
.chromestyle ul li{
display: inline;
}
 
.chromestyle ul li a{
color:#FFFFFF;
font-size:10px;
padding: 4px 7px;
margin: 0;
text-decoration: none;
 
}
 
/*.chromestyle ul li a:hover, .chromestyle ul li a.selected{ script dynamically adds a class of "selected" to the current active menu item*/
/*background: url(chromebg-over.gif) center center repeat-x; THEME CHANGE HERE*/
/*}
 
/* ######### Style for Drop Down Menu ######### */
 
.dropmenudiv{
position:absolute;
top: 20px;
border: 1px solid #BBB; /*THEME CHANGE HERE*/
border-bottom-width: 0;
line-height:18px;
z-index:450;
background-color: white;
width: 200px;
visibility: hidden;
font-family: "Lucida Grande" ,"Verdana", "Trebuchet";
font-size: 10px;
color: #2D4D79;
margin:10px 0 0 5px;
}
 
 
.dropmenudiv a{
width: auto;
display: block;
text-indent: 3px;
border-bottom: 1px solid #BBB; /*THEME CHANGE HERE*/
padding: 2px 0;
text-decoration: none;
 
}
 
* html .dropmenudiv a{ /*IE only hack*/
width: 100%;
}
 
.dropmenudiv a:hover{ /*THEME CHANGE HERE*/
background-color: #F0F0F0;
}
 
 
 
 
//////////////////////////Global CSS
 
 
<style type="text/css">
	@import "all.css"; /* just some basic formatting, no layout stuff */
	
	
	
	 
	body {
		
		}
		
 
	
	
		/*
		IE5x PC mis-implements the box model. Because of that we sometimes have
		to perform a little CSS trickery to get pixel-perfect display across browsers.
		The following bit of code was proposed by Tantek Celik, and it preys upon a CSS
		parsing bug in IE5x PC that will prematurly close a style rule when it runs
		into the string "\"}\"". After that string appears in a rule, then, we can override
		previously set attribute values and only browsers without the parse bug will
		recognize the new values. So any of the name-value pairs above this comment
		that we need to override for browsers with correct box-model implementations
		will be listed below.
		
		We use the voice-family property because it is likely to be used very infrequently,
		and where it is used it will be set on the body tag. So the second voice-family value 
		of "inherit" will override our bogus "\"}\"" value and allow the proper value to
		cascade down from the body tag.
 
		The style rule immediately following this rule offers another chance for CSS2
		aware browsers to pick up the values meant for correct box-model implementations.
		It uses a CSS2 selector that will be ignored by IE5x PC.
		
		Read more at http://www.glish.com/css/hacks.asp
		*/
		#centercontent {
		background:#fff;
   		margin-right:201px;
		border:1px solid #CCCCCC;
		width:700px;
		text-align:left;
		voice-family: "\"}\"";
		voice-family: inherit;
   		margin-left: 120px;
		position:absolute;
		top:110px;
		}
		
		#divLocation {
	position:fixed;
	border:#000000;
	width:136px;
	z-index:55;	
	bottom:0px;
	left:0px;
	}
	
	#adSkyRH {
	border:#000000;
	position:absolute;
	width:120px;
	z-index: 10;
	left: 840px;
	top: 110px;
	
	} 
	#adSkyLH {
	border:#000000;
	position:absolute;
	width:120px;
	z-index: 10;
	left: 0px;
	top: 110px;
	
	} 
 
		
			#footer {
		background-image:url(../Images/FooterBG.png); background-repeat:repeat-x;
		width:100%;
		height:40px;
		font-family: "Lucida Grande" , "Trebuchet";
		font-size: 10px;
		color: #666666;
		padding:5px;
		position:fixed;
		bottom:-15px;
		left:0px;
		z-index:50;
		
		}
		
	html>body#centercontent {
   		margin-left: 140px;
   		margin-right:201px;
		}
		
	
		
			.bodyTxt {
	font-family: "Lucida Grande"  ,"Verdana", "Trebuchet";
	font-size: 14px;
	color: #333333;
}
 
 
.bodyTxtSmall {
	font-family: "Lucida Grande" ,"Verdana", "Trebuchet";
	font-size: 10px;
	color: #333333;
}
 
.bodyTxtSmallWhite {
	font-family: "Lucida Grande" ,"Verdana", "Trebuchet";
	font-size: 10px;
	color: #FFFFFF;
}
.bodyTxtSmallBlue {
	font-family: "Lucida Grande" ,"Verdana", "Trebuchet";
	font-size: 10px;
	color: #2D4D79;
}
 
 
.bodyTxtWhite {
	font-family: "Lucida Grande" ,"Verdana", "Trebuchet";
	font-size: 14px;
	color: #FFFFFF;
}
 
.bodyLGWhiteTxt {
	font-family: "Lucida Grande" ,"Verdana", "Trebuchet";
	font-size: 20px;
	color: #FFFFFF;
}
 
.bodyLGBlueTxt {
	font-family: "Lucida Grande" ,"Verdana", "Trebuchet";
	font-size: 20px;
	color: #2D4D79;
}
.bodyBlueTxt {
	font-family: "Lucida Grande" ,"Verdana", "Trebuchet";
	font-size: 14px;
	color: #2D4D79;
}
.rating {
	font-family: "Lucida Grande" ,"Verdana", "Trebuchet";
	font-size: 90px;
	color: #2D4D79;
}
.redTxt {
	font-family: "Lucida Grande" ,"Verdana", "Trebuchet";
	font-size: 14px;
	color: #990000;
}
.greenTxt {
	font-family: "Lucida Grande" ,"Verdana", "Trebuchet";
	font-size: 14px;
	color: #339900;
}
 
	
		
	p,h1,pre {
		margin:10px 10px 10px 10px;
		}
		
	
 
	h1 {
		font-size:14px;
		color:#224674;
		font-family: "Lucida Grande" , "Trebuchet";
		
		}
		
	
	
	#rightcontent p {
		font-size:10px
		}
		
	#login {
		margin-left:10px;
		margin-right:58px;
		float:right; 
		position:absolute;
		left:850px;
		top:5px;
		}
		
		#signedIn { 
		background-image:url(../Images/Home/SignedInBG.jpg); 
		background-repeat:no-repeat; 
		position:absolute; 
		top:0px; 
		left:712px; 
		width:170px; 
		height:110px; 
		padding:10px;
		}
		
	#helpTop {
	background-image:url(../Images/Help/HelpBG_r1_c1.jpg); 
	background-repeat:no-repeat;
	height:20px;
	}
	
	#helpMiddle {
	background-image:url(../Images/Help/HelpBG_r2_c1.jpg); 
	background-repeat:repeat-y;
	padding: 0 100px 0 0;
 
	}
	
	.helpTxt {
	padding:0px 20px 0px 10px;
	font-size:10px;
	}
	
	.closeBtn{
	padding:40px 20px 0px 20px;
	}
	
	#helpBottom {
	background-image:url(../Images/Help/HelpBG_r3_c1.jpg); 
	background-repeat:no-repeat;
	height:73px;
	
	}
	
	#mainContentContainer {
	padding:10px 10px 10px 10px;
	}
	
	.clearFix {overflow: hidden; clear: right; font-size: 0px; height: 0px}	
	
	.blend img {
opacity: 0;
-moz-opacity: 0;
-khtml-opacity:0;
filter: alpha(opacity=0);
}
 
 .shitList {
 border:#669900 1px solid;
 background-color:#666600;
 font-family: "Lucida Grande" ,"Verdana", "Trebuchet";
	font-size: 15px;
 	color: #666600;
 }
 
 .loveList {
 border: #FF0066 1px solid;
 background-color:#FF0066;
 font-family: "Lucida Grande" ,"Verdana", "Trebuchet";
	font-size: 15px;
	color:#FF0066;
 
 }
 
.myChallTimers {
border-top: thin #CCCCCC solid;  
border-bottom:none; 
border-left:none; 
border-right:none; 
background-color:#FFFFFF;
font-family: "Lucida Grande" ,"Verdana", "Trebuchet";
font-size: 20px;
color: #2D4D79;
}
.pastChall {
border-top: thin #CCCCCC solid;  
border-bottom:none; 
border-left:none; 
border-right:none; 
background-color:#FFFFFF;
font-family: "Lucida Grande" ,"Verdana", "Trebuchet";
font-size: 14px;
color: #666666;
}
 
	#microTop {
	background-image: url(../Images/MyCC/Micro/MicroBGTop.jpg);
	background-repeat:no-repeat;
	height:20px;
	}
	
	#microMiddle {
	background-image: url(../Images/MyCC/Micro/MicroBGMiddle.jpg);
	background-repeat:repeat-y;
	padding: 0 100px 0 0;
 
	}
	
	#microBottom {
	background-image: url(../Images/MyCC/Micro/MicroBGBottom.jpg);
	background-repeat:no-repeat;
	height:73px;
	
	}
	
		#miniTop {
	background-image: url(../Images/MyCC/Mini/MiniBGTop.jpg);
	background-repeat:no-repeat;
	height:20px;
	}
	
	#miniMiddle {
	background-image: url(../Images/MyCC/Mini/MiniBGMiddle.jpg);
	background-repeat:repeat-y;
	padding: 0 100px 0 0;
 
	}
	
	#miniBottom {
	background-image: url(../Images/MyCC/Mini/MiniBGBottom.jpg);
	background-repeat:no-repeat;
	height:73px;
	
	}
	
		#mediumTop {
	background-image: url(../Images/MyCC/Medium/MediumBGTop.jpg);
	background-repeat:no-repeat;
	height:20px;
	}
	
	#mediumMiddle {
	background-image: url(../Images/MyCC/Medium/MediumBGMiddle.jpg);
	background-repeat:repeat-y;
	padding: 0 100px 0 0;
 
	}
	
	#mediumBottom {
	background-image: url(../Images/MyCC/Medium/MediumBGBottom.jpg);
	background-repeat:no-repeat;
	height:73px;
	
	}
	
		#mammothTop {
	background-image: url(../Images/MyCC/Mammoth/MammothBGTop.jpg);
	background-repeat:no-repeat;
	height:20px;
	}
	
	#mammothMiddle {
	background-image: url(../Images/MyCC/Mammoth/MammothBGMiddle.jpg);
	background-repeat:repeat-y;
	padding: 0 100px 0 0;
 
	}
	
	#mammothBottom {
	background-image: url(../Images/MyCC/Mammoth/MammothBGBottom.jpg);
	background-repeat:no-repeat;
	height:73px;
	
	}
 	
	#dareTop {
	background-image: url(../Images/MyCC/Dare/DareBGTop.jpg);
	background-repeat:no-repeat;
	height:20px;
	}
	
	#dareMiddle {
	background-image: url(../Images/MyCC/Dare/DareBGMiddle.jpg);
	background-repeat:repeat-y;
	padding: 0 100px 0 0;
 
	}
	
	#dareBottom {
	background-image: url(../Images/MyCC/Dare/DareBGBottom.jpg);
	background-repeat:no-repeat;
	height:73px;
	
	}
	
	#comTop {
	background-image: url(../Images/MyCC/Community/ComBGTop.jpg);
	background-repeat:no-repeat;
	height:20px;
	}
	
	#comMiddle {
	background-image: url(../Images/MyCC/Community/ComBGMiddle.jpg);
	background-repeat:repeat-y;
	padding: 0 100px 0 0;
 
	}
	
	#comBottom {
	background-image: url(../Images/MyCC/Community/ComBGBottom.jpg);
	background-repeat:no-repeat;
	height:73px;
	
	}
	
 
</style>
</head>
</html>

Open in new window

0
Comment
Question by:RowdyBurns
2 Comments
 
LVL 13

Accepted Solution

by:
myderrick earned 500 total points
ID: 24140916
0
 

Author Closing Comment

by:RowdyBurns
ID: 31569882
Thanks for the tip! RyanFait might be a Genius.
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

SSL stands for “Secure Sockets Layer” and an SSL certificate is a critical component to keeping your website safe, secured, and compliant. Any ecommerce website must have an SSL certificate to ensure the safe handling of sensitive information like…
Is your Office 365 signature not working the way you want it to? Are signature updates taking up too much of your time? Let's run through the most common problems that an IT administrator can encounter when dealing with Office 365 email signatures.
In this tutorial viewers will learn how to embed custom externally-hosted Google Fonts using the Google Font API in CSS Go to the Google Fonts website at google.com/fonts: Browse or search based on font properties or name to find a suitable font for…
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

856 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question