gwmbox
02-05-2008, 05:02 AM
OK here is some code I have been working with and for whatever reason I cannot seem to get the same look in IE7 and FF2
The link should have a thin blue border around all of it, it works fine in FF but not IE(7). IE only shows the left and right borders
I have set the Body to have 0 for both margin and padding as I do not want any padding etc around the content, I have also as shown set the height to be 100% and the extra 1 px so the scroll bar is always shown - stops the jumping for pages without and then with scroll bars :)
I cannot work out why the conflict exists - hope you can enlighten me :)
Oh and any suggestions to tidy up or minimise my code here is welcomed :)
<style>
html {
/* this is a hack to force scrollbars on at
all times so that the page does not jump
when going from short to long pages */
height: 100%;
margin-bottom: 1px;
}
body {
margin: 0;
padding: 0;
}
a.pgmenu,
a:link.pgmenu {
font-family: Arial, Helvetica, sans-serif;
font-size: 12px;
color: White;
text-decoration: none;
padding: 2px 3px 2px 3px;
border: 1px solid #1E90FF;
background-color: Black;
}
a:visited.pgmenu {
text-decoration: none;
color: White;
}
a:hover.pgmenu,
a:active.pgmenu {
border: 1px solid Green;
background-color: #003500;
color: White;
}
img.pgmenu {
vertical-align: text-bottom;
border: none;
}
</style>
and just for a very basic example
<body bgcolor="#000000">
<a href="http://asite.com/" class="pgmenu">My Test</a>
Cheers for all your help
The link should have a thin blue border around all of it, it works fine in FF but not IE(7). IE only shows the left and right borders
I have set the Body to have 0 for both margin and padding as I do not want any padding etc around the content, I have also as shown set the height to be 100% and the extra 1 px so the scroll bar is always shown - stops the jumping for pages without and then with scroll bars :)
I cannot work out why the conflict exists - hope you can enlighten me :)
Oh and any suggestions to tidy up or minimise my code here is welcomed :)
<style>
html {
/* this is a hack to force scrollbars on at
all times so that the page does not jump
when going from short to long pages */
height: 100%;
margin-bottom: 1px;
}
body {
margin: 0;
padding: 0;
}
a.pgmenu,
a:link.pgmenu {
font-family: Arial, Helvetica, sans-serif;
font-size: 12px;
color: White;
text-decoration: none;
padding: 2px 3px 2px 3px;
border: 1px solid #1E90FF;
background-color: Black;
}
a:visited.pgmenu {
text-decoration: none;
color: White;
}
a:hover.pgmenu,
a:active.pgmenu {
border: 1px solid Green;
background-color: #003500;
color: White;
}
img.pgmenu {
vertical-align: text-bottom;
border: none;
}
</style>
and just for a very basic example
<body bgcolor="#000000">
<a href="http://asite.com/" class="pgmenu">My Test</a>
Cheers for all your help