Skip to content

Instantly share code, notes, and snippets.

@ghostbar
Created September 12, 2011 04:49
Show Gist options
  • Save ghostbar/1210608 to your computer and use it in GitHub Desktop.
Save ghostbar/1210608 to your computer and use it in GitHub Desktop.
<!doctype html>
<head>
<link rel="stylesheet" href="style.css">
</head>
<body>
<img id="bg" src="/img/bg.jpg">
<p>Content</p>
</body>
</html>
img#bg {
min-width: 100%;
min-height: 100%;
/* Proportionate re-dimension */
width: 100%;
height: auto;
position: fixed; top: 0; left: 0;
z-index: -1;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment