I'm having a problem with Chrome rendering my page fine when loaded locally, but something goes wrong once the page is online. The first thing I did was check Safari, because they both share the same rendering engine. Safari renders my page fine.
Clicking on a link on the page and pressing the back button causes the page to load fine as well.
Here is an image showing how the page loads locally on Chrome:
And here the header is pushed down once the page is online:
Here is the relevant html:
<!-- header -->
<div id="header2">
<a href="#"><img src="images/detailpages/logo.png" alt="logo" /></a>
<ul>
<li><a href="#">Features</a></li>
<li><a href="#">Pricing</a></li>
<li class="blue"><a href="#">Sign Up</a><a href="#">Log In</a></li>
<li><form><input type="text" name="form" placeholder="type another channel" id="navsearch" /><img src="images/detailpages/search.png" alt="search" /></form></li>
</ul>
</div>
<!-- end header -->
And CSS:
#header2 {
position: relative;
z-index: 999;
height: 40px;
width: 100%;
background: #000;
box-shadow: 0em 0em 0.5em #000;
-webkit-box-shadow: 0em 0em 0.5em #000; /* safari */
/* header nav type */
font-family: "Varela Round", Helvetica, Arial, sans-serif;
font-size: 15px;
}
#header2 ul {
float: right;
list-style-type: none;
}
#header2 li {
display: block;
float: left;
height: 32px;
margin: 10px 16px 0;
}
/* sign up/log in button */
#header2 li.blue {
background: url('../images/detailpages/login.png');
width: 170px;
height: 40px;
margin: 0;
}
#header2 li.blue a {
display: block;
float: left;
margin: 10px 3px 0 24px;
}
#header2 input {
height: 22px;
width: 220px;
padding: 0 8px;
font-family: "Varela Round", Helvetica, Arial, sans-serif;
font-size: 14px;
color: #333;
}
#header2 form img {
display: block;
float: right;
padding-left: 5px;
}
This guy had the same problem but it doesn't look like there was a solution: CSS rendering in Chrome differs online from offline
My bet is you have (maybe accidentally) changed Chrome's Zoom settings for either your online or your offline domain.
Press Ctrl + 0 to reset the zoom level to find out.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With