Log In · Register

 
 
Closed TopicStart new topic
begginer's html help., problem with browsers
BurgerKing316
post Jul 26 2008, 07:16 PM
Post #1


Member
**

Group: Member
Posts: 21
Joined: Apr 2007
Member No: 517,535



i'm experimenting with/learning html, and i want to know how to make something look the same in mozilla and ie.

how it looks in mozilla

how it looks in ie

i want it to look EXACTLY like it does in mozilla, in ie.

i'm not too smart with this, so i was wondering if anyone could help.

here is the code i used:
CODE
<table class="nav">
<tr>
<td>
<ul><li><a href="#">alcho</a></li><li><a href="#">riglant</a></li><li><a href="#">cremme</a></li><li><a href="#">dieordus</a></li><li class="last"><a href="#">flamboo</a></li></ul>
</td>
</tr>
</table>

<style type="text/css">
.nav {margin:0px;padding:0px;background-color:1BE4AD;display:block;}
.nav ul {margin:0px;padding:0px;display:inline;list-style:none;}
.nav li {margin:0px;padding:8px 0px;display:inline;border-right:1px solid white;}
li.last {border-right:0px;}
.nav a {padding:10px;font:normal 12px arial;text-decoration:none;background-color:000;}
.nav a:link, .nav a:visited {color:fff;}
.nav a:hover {background-color:777777;}
.nav a:active, .nav a:focus {background-color:333333;}
</style>
 
venti-anemoi
post Jul 26 2008, 07:58 PM
Post #2


torn
*****

Group: Official Designer
Posts: 953
Joined: Oct 2004
Member No: 55,718



IE and FF add paddings in different ways. I can't remember which is which, but one of them will add the padding in addition to the width, and the other will include the padding as part of the width.

For example, if you specify a div as 100px wide and 200px long with a padding of 5px all around, one browser will make the div 100px by 200px but the content of the div will only take up 90px by 190px, and the other will make the div 110px by 210px with the content taking up 100px by 200px. (Does that make sense?)

I'm not sure if there's some kind of trick around this, but what I would do is make each link a set width and height (so all of them are the same width and height) and that way you don't have to worry about paddings.
 
BurgerKing316
post Jul 26 2008, 08:33 PM
Post #3


Member
**

Group: Member
Posts: 21
Joined: Apr 2007
Member No: 517,535



thanks :D that helped a lot

but there is just one more thing.

is there a way to make it so that green bar goes all the way across the screen in ie like it does in mozilla?
 
BurgerKing316
post Jul 26 2008, 08:45 PM
Post #4


Member
**

Group: Member
Posts: 21
Joined: Apr 2007
Member No: 517,535



never mind, i got it ;]

topic closed
 
karmakiller
post Jul 26 2008, 10:01 PM
Post #5


DDR \\ I'm Dee :)
*******

Group: Mentor
Posts: 8,662
Joined: Mar 2006
Member No: 384,020



Heh, you can't close topics. But I can close it for you. wink.gif
 
karmakiller
post Jul 26 2008, 10:02 PM
Post #6


DDR \\ I'm Dee :)
*******

Group: Mentor
Posts: 8,662
Joined: Mar 2006
Member No: 384,020



Topic Closed, and Moved to Resolved Topics. Please PM a moderator if you would like this reopened.
 

Closed TopicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members: