empty css bgimg url does xtra request
if u set background-image url to empty string, it causes an additional page request/reload
by Nickleus
HTML
<script src="http://imgur.com/AIFGCVt"></script>
<body>
<div id="bgimg">
css background-image url gets set by jquery in document.ready. an empty url string ("") will result in 2 requests instead of 1. when u run this n look at th "network" tab in chrome debugger, u'll c 2 requests to "_display/":
<img style="width:100%" src="http://i.imgur.com/AIFGCVt.png">
</div>
</body>
JavaScript
function setBgImgToEmptyUrlString() {
$("#bgimg").css("background-image", "url('')");
}
$(document).ready(function() {
setBgImgToEmptyUrlString(); // if u comment this out, then run again, u'll only c 1 request to "_display/"
});