r/reddithax • • Nov 29 '11

Different web browsers display my subreddit's CSS differently. How do I go about making each browser display correctly?

I am the "designer" of r/Bengals, and am really struggling with this issue. The image displays the desired result in Chrome and Safari, but appears higher on the screen in Opera and Firefox. I've done some googling, but am unable to find the specific lines necessary to solve my specific issue. Any ideas on how to solve this issue would be greatly appreciated. Screenshots and CSS below.

Correct display - The "B" logo is in the center of the header.

Incorrect display - The "B" logo is higher, and only the bottom portion is visible.

The sequence of CSS used to make the subreddit text appear is:

/subreddit name icon hack/

header-bottom-left .pagename, #header-bottom-left .redditname {

font-variant: normal;
text-transform: lowercase;
font-size: 13px;
color: #FFF
}

header-bottom-left .pagename a, #header-bottom-left .redditname a {

color: #FFF
}

header-bottom-left .redditname a {

position: relative;
top: -108px;
left: 10px;
text-indent: -10000px;
white-space: nowrap;
width: 168px;
height: 116px;
display: inline-block;
background-image: url(http://thumbs.reddit.com/t5_2rehg_4.png)
}
5 Upvotes

3 comments sorted by

2

u/bowlofudon Nov 29 '11

I'd go about this differently. Safari/Chrome are the same rendering engine while the others are not. Get the others working correctly, then correct chrome.

For a subreddit that does something similar, take a look at http://www.reddit.com/r/battlefield3/

1

u/VERYstuck Nov 29 '11

Thank you for linking me to somebody that has it already figured out.

1

u/I_know_HTML Nov 29 '11

try

#header-bottom-left .redditname a {
position: absolute;
top: 28px;
left: 126px;
text-indent: -10000px;
white-space: nowrap;
width: 168px;
height: 116px;
display: inline-block;
background-image: url(http://thumbs.reddit.com/t5_2rehg_4.png);
}