Page 1 of 1

DIV not showing up in IE

Posted: Wed Jun 22, 2011 4:56 pm
by Tim
Hey guys,

Running into some more trouble, but this time it seems to be a compatibility issue with Internet Explorer (why do they have to be so behind?!).

If you don't mind, please load my game in Chrome Firefox, or something other than Internet Explorer, and then load it with Internet Explorer. I have made a test account so you guys can login and see what I'm talking about.

www . draiaonline . com

Username: test
Password: test

If you look at the top right of the screen I have a div section that shows the users online as well as links to the forum, rules, etc. If a player has a certain access level, there is also an admin panel in this section. It looks great in Firefox and Chrome, but in Internet Explorer it's completely blank.

Here is my style.css

Code: Select all

* { padding: 0; margin: 0; }

A:link {
 COLOR: white;
 }

A:visited {
 COLOR: white;
}

A:active {
 COLOR: white;
}

A:hover {
 COLOR: white;
}

body {
 font-family: Verdana, Arial, Helvetica, sans-serif;
 font-size: 10px;
 text-align:center; /*For IE6 Shenanigans*/  
 margin-top:20px;
 background: #1C1C1C;
}

p {
 padding: 10px;
}

#wrapper { 
 z-index: 0;
 margin: 0 auto;
 width: 1000px;
}

#header {
 z-index: 1;
 color: #333;
 width: 1000px;
 float: left;
 text-align: left; 
 height: 100px;
 background: #2E2E2E;
 border-style: dashed;
 border-width: 1px;
 border-color: #FFFFFF
}

#top_right {
 z-index: 2;
 color: white;
 font-size: 12px;
 width: 250px;
 position: absolute; 
 height: 60px;
 top: 5%;
 left: 65%;
 text-align: right;
 background: #2E2E2E;
}

#user_information {
 float: left;
 width: 1000px;
 height: 15px;
 color: #333;
 font-size: 9px;
 background: #5E5E5E;
 border-style: dashed;
 border-width: 1px;
 border-color: #FFFFFF
}

#navigation {
 float: left;
 width: 1000px;
 height: 30px;
 color: #333;
 background: #474747;
 border-style: dashed;
 border-width: 1px;
 border-color: #FFFFFF
}

#content { 
 float: left;
 color: #FFFFFF;
 background: #2E2E2E;
 height: 500px;
 width: 1000px;
 display: inline;
 border-style: dashed;
 border-width: 1px;
 border-color: #FFFFFF
 overflow: auto;
}

#footer { 
 width: 1000px;
 height: 15px;
 clear: both;
 color: #333;
 background: #696969;
 border-style: dashed;
 border-width: 1px;
 border-color: #FFFFFF
}

#textheader {
 font-family: Verdana, Arial, Helvetica, sans-serif;
 font-size: 12px;
 font-weight: bold;
 color: white;
}

#text {
 font-family: Verdana, Arial, Helvetica, sans-serif;
 font-size: 11px;
 color: white;
}

Here is my header.php

Code: Select all

<div id="header">
<a href="index.php"><img src="images/logo.png" border=0/></a>
</div>

<div id="top_right">
<?php
$threshold = date('m-d-Y h:i:s A') - 900;  // 900 seconds is equal to 15 minutes.

$user_info_1 = "SELECT * from users where last_seen >= '$threshold'";
$user_info_2 = mysql_query($user_info_1) or die("System: Could not get a list of users online.");
$user_info_3 = mysql_fetch_array($user_info_2);

$users_online = mysql_numrows($user_info_2);

$user_info_1 = "SELECT * from users where username = '$username'";
$user_info_2 = mysql_query($user_info_1) or die ("System: Could not get user information.");
$user_info_3 = mysql_fetch_array($user_info_2);

$user_access = $user_info_3['access'];

echo "[ Users Online: <a style='text-decoration:none' href='/users_online.php'>" . $users_online . " </a> ]";
echo "<br>";
echo "[ Rankings: <a style='text-decoration:none' href='/user_ranks.php'> Users </a> / <a style='text-decoration:none' href='/guild_ranks.php'> Guilds </a> ]";
echo "<br>";
echo "[ <a style ='text-decoration:none' href='guide.php'>Beginners Guide</a> / <a style ='text-decoration:none' href='/forum' target='_blank'>Forum</a> / Rules ]";

if ($user_access > 0)
{	
	echo "<br>";
	echo "[ <a style='text-decoration:none' href='/admin_panel.php'>Admin Panel</a> ]";
}
?>
</div>
Thank you for your time. :)

Re: DIV not showing up in IE

Posted: Wed Jun 22, 2011 5:24 pm
by Jackolantern
I see what you mean, and unfortunately, I have no idea why it is doing that. On maybe a related note, what are you putting IE into quirks mode for? That could be causing the problem.

Re: DIV not showing up in IE

Posted: Wed Jun 22, 2011 5:36 pm
by Tim
Jackolantern wrote:I see what you mean, and unfortunately, I have no idea why it is doing that. On maybe a related note, what are you putting IE into quirks mode for? That could be causing the problem.
That was my latest attempt to fix this problem. Removed and still the same thing.

Hmm, does anyone know if there is another way to get the div at that position that I could try?

Re: DIV not showing up in IE

Posted: Wed Jun 22, 2011 7:41 pm
by hallsofvallhalla
adding a doc type

Code: Select all

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

Re: DIV not showing up in IE

Posted: Thu Jun 23, 2011 3:10 am
by Tim
hallsofvallhalla wrote:adding a doc type

Code: Select all

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
Thank you for your reply. Unfortunately there was no change after adding this bit of code. I tried adding it to both my index.php and header.php

Hmm ...