473,386 Members | 1,621 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

IE Gap Problem

TheServant
1,168 Expert 1GB
Hey guys,
I have been teaching myself web design and using a lot of php. I have been going great, slowly but surely, however I have a problem. If you open up my home page: (http://supremewarfare.com/main/home.php) in firefox/Opera, everything is good. However if you open it up in IE6 or 7 (haven't tried 5 but I presume it's the same), there is a serious gap in my table and I am not sure how to fix it? Have a look at the source code and let me know if you see my mistake!

This is my CSS:
Expand|Select|Wrap|Line Numbers
  1. @charset "utf-8";
  2. /* CSS Document */
  3.  
  4. p.error {color:#FF0000; font-weight:bold}
  5.  
  6. td.title {
  7.     color:#990000;
  8.     font-style:italic; font-weight:bold
  9. }
  10. td.text {color:#CC0000; }
  11.  
  12. table.main {background-color:#000000; width:100%; }
  13.  
  14. td.TL_1 { background-image:url(Table/Table_TL.jpg); width:50; height:50; background-repeat:no-repeat }
  15. td.TR_1 { background-image:url(Table/Table_TR.jpg); width:50; height:50; background-repeat:no-repeat }
  16. td.BL_1 { background-image:url(Table/Table_BL.jpg); width:50; height:50; background-repeat:no-repeat }
  17. td.BR_1 { background-image:url(Table/Table_BR.jpg); width:50; height:50; background-repeat:no-repeat }
  18. td.T_1 { background-image:url(Table/Table_T.jpg); width:auto; height:50; background-repeat:repeat-x }
  19. td.L_1 { background-image:url(Table/Table_L.jpg); width:50; height:auto; background-repeat:repeat-y }
  20. td.B_1 { background-image:url(Table/Table_B.jpg); width:auto; height:50; background-repeat:repeat-x }
  21. td.R_1 { background-image:url(Table/Table_R.jpg); width:50; height:auto; background-repeat:repeat-y }
  22. td.BG_1 { background-image:url(Table/Table_BG.jpg); width:auto; height:auto; background-repeat:repeat }
  23.  
  24. td.TL_2 { background-image:url(Table_2/Table_TL.gif); width:20; height:20; background-repeat:no-repeat }
  25. td.TR_2 { background-image:url(Table_2/Table_TR.gif); width:20; height:20; background-repeat:no-repeat }
  26. td.BL_2 { background-image:url(Table_2/Table_BL.gif); width:20; height:20; background-repeat:no-repeat }
  27. td.BR_2 { background-image:url(Table_2/Table_BR.gif); width:20; height:20; background-repeat:no-repeat }
  28. td.T_2 { background-image:url(Table_2/Table_T.gif); width:auto; height:20; background-repeat:repeat-x }
  29. td.L_2 { background-image:url(Table_2/Table_L.gif); width:20; height:auto; background-repeat:repeat-y }
  30. td.B_2 { background-image:url(Table_2/Table_B.gif); width:auto; height:20; background-repeat:repeat-x }
  31. td.R_2 { background-image:url(Table_2/Table_R.gif); width:20; height:auto; background-repeat:repeat-y }
  32.  
  33. td.creator { color:#FF0000; font-style:italic; text-align:right; }

The Servant
Feb 6 '08 #1
30 3099
drhowarddrfine
7,435 Expert 4TB
IE6 or 7 (haven't tried 5 but I presume it's the same)
Anyone still using IE5 doesn't expect to view pages properly and doesn't deserve to.

You will never get any version of IE to pretend to act like a modern browser without a proper doctype. See the article about doctypes under Howtos at the top of this page in the html/css section.
Feb 7 '08 #2
TheServant
1,168 Expert 1GB
Cheers, although, when I put the DTD at the top of the page, I get this:

Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at /home/supre8/public_html/main/session_control.php:4) in /home/supre8/public_html/main/session_control.php on line 7

Also, now my page looks much worse?!
Feb 7 '08 #3
Death Slaught
1,137 1GB
Run it through these validators:

HTML/XHTML

CSS

If your problems still persist once you fix any you have just post back with your HTML and CSS, or a link to a test site if you have one.

^_^ Hope it helps, Thanks, Death
Feb 7 '08 #4
drhowarddrfine
7,435 Expert 4TB
Cheers, although, when I put the DTD at the top of the page, I get this:

Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at /home/supre8/public_html/main/session_control.php:4) in /home/supre8/public_html/main/session_control.php on line 7
Has nothing t do with adding the doctype.
Also, now my page looks much worse?!
The doctype is the set of rules you are telling the browser you are using. You didn't specify any before so it reverted to 1996 rules. Now the rules changed to modern rules and that's why your page changed. Fix the validation errors first.
Feb 7 '08 #5
TheServant
1,168 Expert 1GB
The source is too big to post, but the validator gives me heaps of errors which I don't think are right? It is telling me, basically that all the html statements are wrong: eg.
Line 6, Column 5: document type does not allow element "br" here.
Line 7, Column 2: document type does not allow element "b" here.
Also, once I use a DTD, I my sessions are stuffed? Have a look at the site to firstly see the mess ups happening with gaps now that I am using a DTD and also you can see the source there.

Thanks for your help.
Feb 7 '08 #6
Death Slaught
1,137 1GB
What I see right off is that you have code outside of your 'html' tag, which isn't allowed. (i'll add more as I see it).

Another thing you can't put external stylesheets outside of the 'head' tags. The same things with external scripts. Furtheremore, you're using alot of invalid styles. Copy and paste this, you only have 39 errors left (I left some so you can get an idea of what you are doing wrong).

[HTML]
<!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">
<html>
<head>
<title>Supreme Warfare - Home</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<link href="../main/themes/burnt_paper/burnt_paper.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="../main/scripts/menu_scripts/JSCookMenu.js"></script>
<link rel="stylesheet" href="../main/scripts/menu_scripts/themered.css" type="text/css" />
<script type="text/javascript" src="../main/scripts/menu_scripts/theme.js"></script>
<link href="../age_0/themes/supwar.css" rel="stylesheet" type="text/css" />
<link href="../age_0/themes/supwar.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script>
</head>
<body bgcolor="#000000" >
<br />
<b>Warning</b>: session_start() [<a href='function.session-start'>function.session-start</a>]: Cannot send session cookie - headers already sent by (output started at /home/supre8/public_html/main/session_control.php:4) in <b>/home/supre8/public_html/main/session_control.php</b> on line <b>7</b><br />
<br />
<b>Warning</b>: session_start() [<a href='function.session-start'>function.session-start</a>]: Cannot send session cache limiter - headers already sent (output started at /home/supre8/public_html/main/session_control.php:4) in <b>/home/supre8/public_html/main/session_control.php</b> on line <b>7</b><br />

<p class="error">Session: 82d0c7588b67e05558a2723fcb1d1a6f view number: 1.</p>
<p class="error">Name: .</p>
<table style="width:100%; border:2px solid #660000;" cellpadding="0" cellspacing="0">
<tr>
<td><a href="../main/home.php"><img src="../main/pics/Banner.gif" alt="Banner" name="Banner" style="height:199px;" border="0"></a></td>
</tr>
</table>


<!-- /////////////////////////////////////////////////////////////////////////////////
//////// Menu Code //////
///////////////////////////////////////////////////////////////////////////////////-->
<div id="myMenuID">
<script type="text/javascript"><!--
var myMenu =
[
[null,'Home','../main/home.php','_self','Goto Home'],
[null,'Forums','../forums/index.php','_blank','Goto Forums'],
[null,'About Us','../main/about.php','_self','Goto About Us'],
[null,'Contact Us','../main/contact.php','_self','Goto Contact Us'],
[null,'Links','../main/links.php','_self','Goto Links',
[null,'War of Empires','http://www.warofempires.com/','_blank','Goto War of Empires'],
[null,'Lunar Pages Hosting','http://www.lunarpages.com/id/TheGodfather','_blank','Goto LunarPages'],
[null,'AW Surveys','http://www.AWSurveys.com/HomeMain.cfm?RefID=TheServant','_blank','Goto Surveys']
],
[null,'Flash Games','../main/games.php','_self','Goto Games'],
[null,'Supreme Warfare','','','',
[null,'Command','../age_0/command.php','_self','Goto Command'],
[null,'Attack','../age_0/attack.php','_self','Goto Attack'],
[null,'Attack Log','../age_0/attacklog.php','_self','Goto Attack Log'],
[null,'Heroes','../age_0/hero.php','_self','Goto Hero'],
[null,'Army','../age_0/army.php','_self','Goto Army'],
[null,'Alliance','../age_0/alliance.php','_self','Goto Alliance'],
[null,'Citizens','../age_0/citizens.php','_self','Goto Citizens'],
[null,'Register','../main/register.php','_self','Goto Register'],
[null,'Logout','../main/log_out.php','_self','Goto Logout'],
],
];
--></script>
</div><br /><br />

<script type="text/javascript"><!--
cmDraw ('myMenuID', myMenu, 'hbr', cmTheme);
--></script>
<!-- /////////////////////////////////////////////////////////////////////////////////
///////////////////////////////////////////////////////////////////////////////////-->

<table style="width:100%; background-color:#000;" border="0" cellpadding="0" cellspacing="0">
<tr>
<td style="width:200px;" rowspan="5" valign="top">
<table class="side_bar_main" border="0" cellspacing="0" cellpadding="0" >
<tr>
<td class="side_bar_T">&nbsp;</td>
</tr>
<tr>
<td class="side_bar_BG">
<center>
<div id="form">
<b align="center">Username:</b><br />
<input name="user_name" type="text" style="width:150px;" /><br />
<b align="center">Password:</b><br />
<input name="user_password" type="password" style="width:150px;" /><br /><br />
<input type="image" src="../age_0/pics/side_bar_login.gif" alt="Login" />
</div>
<a href="../age_0/forgot_password.php" target="_self"><b>Forgot Password</b></a><br />
<a href="../main/register.php" target="_self"><b>Register</b></a> </center>
</td>
</tr>
<tr>
<td class="side_bar_B">&nbsp;</td>
</tr>
</table></td>
<td>&nbsp;</td>
<td style="height:60px;" valign="top">
</td>
<td>&nbsp;</td>
<td>&nbsp;</td>
</tr>
<tr>
<td class="TL_1">&nbsp;</td>
<td class="T_1">&nbsp;</td>
<td class="TR_1">&nbsp;</td>
<td style="width:140px;" rowspan="5" align="center" valign="top">
<script type="text/javascript"><!--
google_ad_client = "pub-8625251004016542";
//skyscraperadd
google_ad_slot = "5420140263";
google_ad_width = 120;
google_ad_height = 600;
//--></script>
</td>
</tr>
<tr>
<td class="L_1">&nbsp;</td>
<td class="BG_1" valign="top"> <!-- Logged in check for login display -->
<table style="width:100%; background-color:#000;" border="0" cellspacing="0" cellpadding="0">
<tr>
<td class="TL_2">&nbsp;</td>
<td class="T_2">&nbsp;</td>
<td class="TR_2">&nbsp;</td>
</tr>
<tr>
<td class="L_2">&nbsp;</td>
<td class="title">Login Test</td>
<td class="R_2">&nbsp;</td>
</tr>
<tr>
<td class="L_2">&nbsp;</td>
<td class="text"></td>
<td class="R_2">&nbsp;</td>
</tr>
<tr>
<td class="BL_2">&nbsp;</td>
<td class="B_2">&nbsp;</td>
<td class="BR_2">&nbsp;</td>
</tr>
</table>
</td>
<td class="R_1">&nbsp;</td>
</tr>
<tr>
<td class="BL_1">&nbsp;</td>
<td class="B_1">&nbsp;</td>
<td class="BR_1">&nbsp;</td>
</tr>
<tr>
<td class="creator" colspan="3">Created by xxxx</p></td>
</tr>
</table>


<!-- /////////////////////////////////////////////////////////////////////////////////
//////// Adds Code //////
///////////////////////////////////////////////////////////////////////////////////-->

<table style="width:899px;" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td style="width:465px;"><!-- Begin BidVertiser code -->
<SCRIPT LANGUAGE="JavaScript1.1" SRC="http://bdv.bidvertiser.com/BidVertiser.dbm?pid=60848&bid=241793" type="text/javascript"></SCRIPT>
<noscript><a href="http://www.bidvertiser.com">marketing</a>
</noscript>
<!-- End BidVertiser code --><br /><br /></td>

<td width="234"><a href="http://www.lunarpages.com/id/TheGodfather" onMouseOver="window.status='http://www.lunarpages.com';return true" onMouseOut="window.status='';return true" target="_blank"><img src="http://www.lunarpages.com/banners/images/06_lunarpages_234x60.gif" alt="Lunarpages.com Web Hosting" border="0" style="border: none" /></a><br /><br /></td>

<td width="200"><form action="https://www.paypal.com/cgi-bin/webscr" method="post">
<input type="hidden" name="cmd" value="_s-xclick">
<input type="image" src="../main/pics/Donate.gif" border="0" name="submit" alt="Make payments with PayPal - it's fast, free and secure!">
<img alt="" border="0" src="https://www.paypal.com/en_AU/i/scr/pixel.gif" width="1" height="1">
<input type="hidden" name="encrypted" value="-----BEGIN PKCS7-----MIIHVwYJKoZIhvcNAQcEoIIHSDCCB0QCAQExggEwMIIBLAIBAD CBlDCBjjELMAkGA1UEBhMCVVMxCzAJBgNVBAgTAkNBMRYwFAYD VQQHEw1Nb3VudGFpbiBWaWV3MRQwEgYDVQQKEwtQYXlQYWwgSW 5jLjETMBEGA1UECxQKbGl2ZV9jZXJ0czERMA8GA1UEAxQIbGl2 ZV9hcGkxHDAaBgkqhkiG9w0BCQEWDXJlQHBheXBhbC5jb20CAQ AwDQYJKoZIhvcNAQEBBQAEgYCiRC302+GGREnBgNvkoqLfV0QB iZ9s736r36xSVM2bTiMqu3JqZtBYmZZCs6SMqJfiLe5hvd29Ly xlJL5WItI9Xbm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/h2GltCegqACGjo55WWJ3WsWsjQ=-----END PKCS7-----
">
</form>
</td>
</tr>
</table>
<!-- /////////////////////////////////////////////////////////////////////////////////
///////////////////////////////////////////////////////////////////////////////////-->

</body>
</html>

[/HTML]

^_^ Thanks, Death
Feb 7 '08 #7
TheServant
1,168 Expert 1GB
You rock Death! I have fixed a lot of errors using that validator. Didn't realise teaching myself meant it was also possible to teach myself wrong ways! Well, I apparently have no more syntax errors, but my problem is still there and now it is also in Firefox. Have another look at my site, http://supremewarfare.com and see if you (or anyone else) can tell me what the gap at the top of the page and the gaps around the content part are from?

The Servant
Feb 8 '08 #8
Death Slaught
1,137 1GB
No problem, it's what I'm here for.

I don't even have to look at the page to tell you how to fix that. Add this rule to one of your CSS files.

Expand|Select|Wrap|Line Numbers
  1.  * { 
  2. margin:0;
  3. padding:0;
  4. }
  5.  
^_^ Thanks, Death

PS - After you get this working, try making your site XHTML 1.0 Strict, instead of transitional. This will give you a little more experience in fixing errors and invalid code.
Feb 8 '08 #9
Death Slaught
1,137 1GB
As for your spaces around your images I know that using:

Expand|Select|Wrap|Line Numbers
  1. vertical-align:bottom;
will get rid of the one in your register page, but as for the other ones i'm not really sure. drhowarddrfine will know, he's the almighty one around here. :)

^_^ Thanks, Death
Feb 8 '08 #10
TheServant
1,168 Expert 1GB
OK, I am back to square one (same initial problem) but my code is much better!

It is validated as Transitional, but I have a few q's about Strict:
1. What should I use instead of
Expand|Select|Wrap|Line Numbers
  1. <br />
? It doesn't seem to like that?
2. With href, why does it not accept the target attribute:
Expand|Select|Wrap|Line Numbers
  1. <a href="../forgot_password.php" target="_self"><b>Forgot Password</b></a>
3. How do I align stuff to the center? It won't accept the
Expand|Select|Wrap|Line Numbers
  1. <center>
code, nor can I use the "align" attribute of
Expand|Select|Wrap|Line Numbers
  1. <div>
?!

Plus my original problem of that black line only on IE :(

PS - Death Slaught thanks for your help with the validation, I will start doing things properly now!
Feb 9 '08 #11
drhowarddrfine
7,435 Expert 4TB
1. What should I use instead of
Expand|Select|Wrap|Line Numbers
  1. <br />
? It doesn't seem to like that?
Remove the space.
EDIT: Do NOT remove the space. This should have worked. See later post.
2. With href, why does it not accept the target attribute:
Expand|Select|Wrap|Line Numbers
  1. <a href="../forgot_password.php" target="_self"><b>Forgot Password</b></a>
There is no such thing in xhtml.
3. How do I align stuff to the center? It won't accept the
Expand|Select|Wrap|Line Numbers
  1. <center>
code, nor can I use the "align" attribute of
Expand|Select|Wrap|Line Numbers
  1. <div>
?!
Neither exists in xhtml. Use CSS.
Expand|Select|Wrap|Line Numbers
  1. p{
  2. text-align:center;
  3. }
for text.
Feb 9 '08 #12
drhowarddrfine
7,435 Expert 4TB
To center an element, use margins:
Expand|Select|Wrap|Line Numbers
  1. div{margin:0 auto}
  2.  
Feb 9 '08 #13
TheServant
1,168 Expert 1GB
Thanks.

So, it won't accept the <b> or <br /> tags in the validator:
Expand|Select|Wrap|Line Numbers
  1. <form action="<?php echo $_SERVER['REQUEST_URI']; ?>" method="post">
  2. <b>Username:</b><br />
  3. <input name="user_name" type="text" style="width:150px;" /><br />
  4. <b>Password:</b><br />
  5. <input name="user_password" type="password" style="width:150px;" /><br /><br />
  6. <input type="image" src="../age_0/pics/side_bar_login.gif" alt="Login" />
  7. </form>
And just confirming, there is no real center function, because margins can't actually center things, but rather offset them, so an a different size display it will be out of whack? Is the only way to use tables and align them like that?

Also, with regards to the href question, in xhtml Strict, how do you open a new page if you can't use the target attribute?

And finally, drhowarddrfine, would you be able to have a look at my site in IE and see if you know why that black line is there?

Thanks for your suggestions.
Feb 9 '08 #14
drhowarddrfine
7,435 Expert 4TB
Thanks.

So, it won't accept the <b> or <br /> tags in the validator
I made an error here because (without re-reading the post) I thought you said <br /> gave you an error in the validator. Without thinking, I automatically said remove the space, but that is wrong. The space is supposed to be there, so I don't know why you would get an error with <br />.
You shouldn't use <b> because that is presentation and presentation is done with CSS.
And just confirming, there is no real center function, because margins can't actually center things, but rather offset them, so an a different size display it will be out of whack? Is the only way to use tables and align them like that?
I'm not following but <center>, too, is presentation and presentation should be styled with CSS.
Also, with regards to the href question, in xhtml Strict, how do you open a new page if you can't use the target attribute?
The target attribute is an attribute for frames yet many people use it in a non-frames environment, such as xhtml strict. You can use 'transitional' to get it to validate.

You will have to google for alternate methods to 'target'.
Feb 9 '08 #15
drhowarddrfine
7,435 Expert 4TB
I don't have Windows on my notebook so I can't check in IE now. The "black line" is a gap between two elements. It could be caused by margins IE is inserting on its own. To test, in your CSS add *{margin:0;padding:0} to see if the line goes away. If that doesn't mess anything else up then that's your fix. Otherwise you may have to localize it to that element.
Feb 9 '08 #16
Death Slaught
1,137 1GB
I'm going to say a lot of what has already been said (by drhowarddrfine).

There isn't anything you should use instead of the <br /> tag. Your problem is that <br /> is an inline element, and inline elements MUST go inside of a block level element. Put the 'contents' of your form in a paragraph like this.

[HTML]<form>
<p>
Username:<br />
</p>
</form>[/HTML]

As drhowarddrfine pointed out the target attribute is used for frames, and besides that I'm not to familier with it (i'll google it in a moment though).

No you can't use the align attribute. You need to use CSS. In your form you used the <b> tag. That (like the align attribute) are no longer valid and shouldn't be used.

I strongly recommend you read this. I think you'll find it very interesting (i've read a lot of books on HTML and CSS. I liked this one the best for its CSS explinations).

^_^ Hope it helps, Thanks,
{\_/}
(' . ')
(")[DEATH](")
(")(")

PS - You can open a link in a new window with JavaScript but I'm not sure if that's what you want.
Feb 11 '08 #17
TheServant
1,168 Expert 1GB
Cheers, that makes sense. I think I will change how I do my <br />'s, however the align thing is a bit of a pain, so for now I will stay with transitional just for that *Please don't hate me*!

So noone has any idea why I have that black line in IE when I look at my page?
Feb 11 '08 #18
Death Slaught
1,137 1GB
That has already been answered by drhowarddrfine.

I don't have Windows on my notebook so I can't check in IE now. The "black line" is a gap between two elements. It could be caused by margins IE is inserting on its own. To test, in your CSS add *{margin:0;padding:0} to see if the line goes away. If that doesn't mess anything else up then that's your fix. Otherwise you may have to localize it to that element.
However, I did notice that that wasn't the solution. What are you using to create the box that surrounds the text 'login test'. I didn't see any code for it in your source so I'm guessing it's in your CSS?

Thanks,
{\_/}
(' . ')
(")[DEATH](")
(")(")
Feb 11 '08 #19
TheServant
1,168 Expert 1GB
php, this is the whole code:

[PHP]
<?php include("../main/session_control.php"); ?>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-Strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">

<!-- /////////////////////////////////////////////////////////////////////////////////
//////// Head Code //////
///////////////////////////////////////////////////////////////////////////////////-->

<head>

<title>Supreme Warfare</title>

<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

<link href="../main/themes/burnt_paper/burnt_paper.css" rel="stylesheet" type="text/css" />
<link href="../age_0/themes/supwar.css" rel="stylesheet" type="text/css" />

<script type="text/javascript" src="../main/scripts/live_time.js"></script>
<script type="text/javascript" src="../main/scripts/menu_scripts/JSCookMenu.js"></script>
<link rel="stylesheet" href="../main/scripts/menu_scripts/themered.css" type="text/css" />
<script type="text/javascript" src="../main/scripts/menu_scripts/theme.js"></script>

</head>


<!-- /////////////////////////////////////////////////////////////////////////////////
//////// Body Code //////
///////////////////////////////////////////////////////////////////////////////////-->

<body class="body_background" onLoad="startclock()">

<p class="error"><?php echo('Session: '.session_id().' view number: '.$_SESSION['view'].'.') ?></p>
<p class="error"><?php echo('Name: '.$_SESSION['user_name'].'.') ?></p>

<table style="width:100%; border:2px solid #660000;" cellpadding="0" cellspacing="0">
<tr>
<td><a href="../main/home.php"><img src="../main/pics/Banner.gif" alt="Banner" style="height:199px; border:0;" /></a></td>
</tr>
</table>





<!-- /////////////////////////////////////////////////////////////////////////////////
//////// Menu Code //////
///////////////////////////////////////////////////////////////////////////////////-->

<div id="myMenuID">
<script type="text/javascript">
var myMenu =
[
[null,'Home','../main/home.php','_self','Goto Home'],
[null,'Forums','../forums/index.php','_blank','Goto Forums'],
[null,'About Us','../main/about.php','_self','Goto About Us'],
[null,'Contact Us','../main/contact.php','_self','Goto Contact Us'],
[null,'Links','../main/links.php','_self','Goto Links',
[null,'War of Empires','http://www.warofempires.com/','_blank','Goto War of Empires'],
[null,'Lunar Pages Hosting','http://www.lunarpages.com/id/TheGodfather','_blank','Goto LunarPages'],
[null,'AW Surveys','http://www.AWSurveys.com/HomeMain.cfm?RefID=TheServant','_blank','Goto Surveys']
],
[null,'Flash Games','../main/games.php','_self','Goto Games'],
[null,'Supreme Warfare','','','',
[null,'Command','../age_0/command.php','_self','Goto Command'],
[null,'Attack','../age_0/attack.php','_self','Goto Attack'],
[null,'Attack Log','../age_0/attacklog.php','_self','Goto Attack Log'],
[null,'Heroes','../age_0/hero.php','_self','Goto Hero'],
[null,'Army','../age_0/army.php','_self','Goto Army'],
[null,'Alliance','../age_0/alliance.php','_self','Goto Alliance'],
[null,'Citizens','../age_0/citizens.php','_self','Goto Citizens'],
[null,'Register','../main/register.php','_self','Goto Register'],
[null,'Logout','../main/log_out.php','_self','Goto Logout'],
],
];
</script>
</div>
<br />
<br />

<script type="text/javascript"><!--
cmDraw ('myMenuID', myMenu, 'hbr', cmTheme);
--></script>


<!-- /////////////////////////////////////////////////////////////////////////////////
//////// Table Code //////
///////////////////////////////////////////////////////////////////////////////////-->

<table style="width:100%; background-color:#000; border:0px;" cellpadding="0" cellspacing="0">
<tr>
<td style="width:200px; height:auto; vertical-align:top;" rowspan="5" ><?php include("../age_0/side_bar.php"); ?></td>
<td>&nbsp;</td>
<td style="height:60px; width:auto; vertical-align:top;" ><?php include("../age_0/top_bar.php"); ?></td>
<td>&nbsp;</td>
<td>&nbsp;</td>
</tr>
<tr>
<td class="TL_1">&nbsp;</td>
<td class="T_1">&nbsp;</td>
<td class="TR_1">&nbsp;</td>
</tr>
<tr>
<td class="L_1">&nbsp;</td>
<td class="BG_1" valign="top"> <!-- Logged in check for login display -->
<?php
if ($_SESSION['user_name'] == NULL)
{
include("../age_0/login_form.php");
}
?>
<table style="width:100%; background-color:#000;" border="0" cellspacing="0" cellpadding="0">
<tr>
<td class="TL_2">&nbsp;</td>
<td class="T_2">&nbsp;</td>
<td class="TR_2">&nbsp;</td>
</tr>[/PHP]

BLACK LINE HERE!!!

[PHP]
<tr>
<td class="L_2">&nbsp;</td>
<td class="title">Login Test</td>
<td class="R_2">&nbsp;</td>
</tr>
<tr>
<td class="L_2">&nbsp;</td>
<td class="text"><?php echo($_SESSION['user_name']); ?></td>
<td class="R_2">&nbsp;</td>
</tr>
<tr>
<td class="BL_2">&nbsp;</td>
<td class="B_2">&nbsp;</td>
<td class="BR_2">&nbsp;</td>
</tr>
</table>
</td>

<td class="R_1">&nbsp;</td>
</tr>
<tr>
<td class="BL_1">&nbsp;</td>
<td class="B_1">&nbsp;</td>
<td class="BR_1">&nbsp;</td>
</tr>
<tr>
<td class="creator" colspan="3">Created by ....</td>
</tr>
</table>




<!-- /////////////////////////////////////////////////////////////////////////////////
//////// Sponsor Code //////
///////////////////////////////////////////////////////////////////////////////////-->

<table style="border:0; width:100%;" cellpadding="0" cellspacing="0">
<tr>
<td align="center">
<table style="border:0; width:auto;" cellpadding="0" cellspacing="0">
<tr valign="baseline">
<td>
<!-- //////// Validator \\\\\\\\ -->
<a href="http://validator.w3.org/check?uri=referer">
<img src="http://www.w3.org/Icons/valid-xhtml10-blue" alt="Valid XHTML 1.0 Transitional" height="31" width="88" />
</a>
</td>
</tr>
</table>
</td>
</tr>
</table>

<!-- /////////////////////////////////////////////////////////////////////////////////
///////////////////////////////////////////////////////////////////////////////////-->



</body>
</html>[/PHP]
Feb 12 '08 #20
Death Slaught
1,137 1GB
Post your CSS that manipulates that section.

Thanks,
{\_/}
(' . ')
(")[DEATH](")
(")(")
Feb 12 '08 #21
TheServant
1,168 Expert 1GB
Expand|Select|Wrap|Line Numbers
  1. @charset "utf-8";
  2. /* CSS Document */
  3.  
  4. * {
  5.     margin:0;
  6.     padding:0;
  7. }
  8.  
  9. body.body_background {
  10.     background-color:#000000;
  11. }
  12.  
  13.  
  14. p.error {color:#FF0000; font-weight:bold}
  15.  
  16.  
  17.  
  18. td.title {
  19.     color:#990000;
  20.     font-style:italic; font-weight:bold
  21. }
  22.  
  23.  
  24. td.text {color:#CC0000; }
  25.  
  26. table.main {background-color:#000000; width:100%; }
  27.  
  28.  
  29. td.TL_1 { background-image:url(Table/Table_TL.jpg); width:50px; height:50px; background-repeat:no-repeat; }
  30. td.TR_1 { background-image:url(Table/Table_TR.jpg); width:50px; height:50px; background-repeat:no-repeat; }
  31. td.BL_1 { background-image:url(Table/Table_BL.jpg); width:50px; height:50px; background-repeat:no-repeat; }
  32. td.BR_1 { background-image:url(Table/Table_BR.jpg); width:50px; height:50px; background-repeat:no-repeat; }
  33. td.T_1 { background-image:url(Table/Table_T.jpg); width:auto; height:50px; background-repeat:repeat-x; }
  34. td.L_1 { background-image:url(Table/Table_L.jpg); width:50px; height:auto; background-repeat:repeat-y; }
  35. td.B_1 { background-image:url(Table/Table_B.jpg); width:auto; height:50px; background-repeat:repeat-x; }
  36. td.R_1 { background-image:url(Table/Table_R.jpg); width:50px; height:auto; background-repeat:repeat-y; }
  37. td.BG_1 { background-image:url(Table/Table_BG.jpg); width:auto; height:auto; background-repeat:repeat; }
  38.  
  39.  
  40. td.TL_2 { background-image:url(Table_2/Table_TL.gif); width:20px; height:20px; background-repeat:no-repeat; }
  41. td.TR_2 { background-image:url(Table_2/Table_TR.gif); width:20px; height:20px; background-repeat:no-repeat; }
  42. td.BL_2 { background-image:url(Table_2/Table_BL.gif); width:20px; height:20px; background-repeat:no-repeat; }
  43. td.BR_2 { background-image:url(Table_2/Table_BR.gif); width:20px; height:20px; background-repeat:no-repeat; }
  44. td.T_2 { background-image:url(Table_2/Table_T.gif); width:auto; height:20px; background-repeat:repeat-x; }
  45. td.L_2 { background-image:url(Table_2/Table_L.gif); width:20px; height:auto; background-repeat:repeat-y; }
  46. td.B_2 { background-image:url(Table_2/Table_B.gif); width:auto; height:20px; background-repeat:repeat-x; }
  47. td.R_2 { background-image:url(Table_2/Table_R.gif); width:20px; height:auto; background-repeat:repeat-y; }
  48.  
  49.  
  50. td.creator { color:#FF0000; font-style:italic; text-align:right; }
  51.  
Feb 13 '08 #22
Death Slaught
1,137 1GB
I'm not really sure what your problem is. I've never used a table layout and don't have much experience on the subject. On the bright side at least it looks fine in FF. When drhowarddrfine gets IE on his notebook then he should be able to provide you an answer. Until then if you have anymore questions just ask.

Thanks,
{\_/}
(' . ')
(")[DEATH](")
(")(")
Feb 13 '08 #23
TheServant
1,168 Expert 1GB
I'm not really sure what your problem is. I've never used a table layout and don't have much experience on the subject. On the bright side at least it looks fine in FF. When drhowarddrfine gets IE on his notebook then he should be able to provide you an answer. Until then if you have anymore questions just ask.

Thanks,
{\_/}
(' . ')
(")[DEATH](")
(")(")
Cheers, I will wait for drhowarddrfine ;)
Feb 13 '08 #24
drhowarddrfine
7,435 Expert 4TB
Well, you'll never see IE on my notebook. I don't use Windows except on my test box and I hate going "down there" to turn it on :)

Like Death, I've never used tables for layout so I was glad to let him wade through all that but now I guess I hafta. :) But I need to read through this whole thread to see what's going on.
Feb 14 '08 #25
Death Slaught
1,137 1GB
Well, you'll never see IE on my notebook. I don't use Windows except on my test box and I hate going "down there" to turn it on :)

Like Death, I've never used tables for layout so I was glad to let him wade through all that but now I guess I hafta. :) But I need to read through this whole thread to see what's going on.
Lol! I'll save you some trouble. There's a screen in the attachment. I just think it's really strange that it seperates three 'td' from the rest of the them. And he's using background images not regular ones. I've never seen anything like it. It just goes to show that IE sucks.

Thanks,
{\_/}
(' . ')
(")[DEATH(")
(")(")
Attached Files
File Type: zip supremewarfare.zip (85.9 KB, 97 views)
Feb 14 '08 #26
drhowarddrfine
7,435 Expert 4TB
See if adding 'display:block' to the image fixes it. If not, try wrapping it in a <p>
Feb 14 '08 #27
TheServant
1,168 Expert 1GB
See if adding 'display:block' to the image fixes it. If not, try wrapping it in a <p>
Thanks for having a look. I will only be able to try these when I get home later, but what did you suggest I wrap in a <p>?
Feb 14 '08 #28
drhowarddrfine
7,435 Expert 4TB
Thanks for having a look. I will only be able to try these when I get home later, but what did you suggest I wrap in a <p>?
Put the image in the <p> and make sure the margins of the <p> are zero.
Feb 14 '08 #29
TheServant
1,168 Expert 1GB
No luck. I will keep working on it and I'll post when I have either more information or a solution. Thanks for your help anyways guys!
Feb 17 '08 #30
TheServant
1,168 Expert 1GB
Hey guys,
Just tried a google search and I'm not all that happy having most of my code, including some keywords on here. Can this thread be deleted or atleast have my code removed for now? The problem has not been solved, but I will work on it on my own until I have something new, so I no longer need/want my code in this thread to be available.

Cheers.
Feb 18 '08 #31

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

Similar topics

11
by: Kostatus | last post by:
I have a virtual function in a base class, which is then overwritten by a function of the same name in a publically derived class. When I call the function using a pointer to the derived class...
117
by: Peter Olcott | last post by:
www.halting-problem.com
18
by: Ian Stanley | last post by:
Hi, Continuing my strcat segmentation fault posting- I have a problem which occurs when appending two sting literals using strcat. I have tried to fix it by writing my own function that does the...
28
by: Jon Davis | last post by:
If I have a class with a virtual method, and a child class that overrides the virtual method, and then I create an instance of the child class AS A base class... BaseClass bc = new ChildClass();...
6
by: Ammar | last post by:
Dear All, I'm facing a small problem. I have a portal web site, that contains articles, for each article, the end user can send a comment about the article. The problem is: I the comment length...
16
by: Dany | last post by:
Our web service was working fine until we installed .net Framework 1.1 service pack 1. Uninstalling SP1 is not an option because our largest customer says service packs marked as "critical" by...
2
by: Mike Collins | last post by:
I cannot get the correct drop down list value from a drop down I have on my web form. I get the initial value that was loaded in the list. It was asked by someone else what the autopostback was...
0
by: =?Utf-8?B?am8uZWw=?= | last post by:
Hello All, I am developing an Input Methop (IM) for PocketPC / Windows Mobile (PPC/WM). On some devices the IM will not start. The IM appears in the IM-List but when it is selected from the...
1
by: sherifbk | last post by:
Problem description ============== - I have 4 clients and 1 server (SQL server) - 3 clients are Monitoring console 1 client is operation console - Monitoring console collects some data from...
9
by: AceKnocks | last post by:
I am working on a framework design problem in which I have to design a C++ based framework capable of solving three puzzles for now but actually it should work with a general puzzle of any kind and I...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
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,...
0
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...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

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.