This also works:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<title>Test</title>
<style type="text/css">
#big {
position: absolute;
left: 0;
right: 0;
top: 0;
bottom: 0;
background: #000;
}
</style>
</head>
<body>
<div id="big"></id>
</body>
</html>
Set up topand bottomshould do the trick (it also works with position: fixed).
source
share