• We’re currently investigating an issue related to the forum theme and styling that is impacting page layout and visual formatting. The problem has been identified, and we are actively working on a resolution. There is no impact to user data or functionality, this is strictly a front-end display issue. We’ll post an update once the fix has been deployed. Thanks for your patience while we get this sorted.

Noobe web page question

Doomer

Diamond Member
Is there any way to make a backround pic dynamically stretch to fit the screen horizonally depending on the screen resolution?

I'm using Dreamweaver.

TIA
 
You kind of have to cheat but using an image and set that to be 100% width and height, eg:

<?xml version="1.0"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
<head>

<title>Page</title>

<style type="text/css">

html,body{margin:0px;padding:0px;}

html{overflow-y:hidden;}
body {height:100%;}

div#content
{
position:absolute;
top:0;
left:0;
z-index:1;
}
img#bgimage
{
position:absolute;
top:0;
left:0;
height:100%;
width:100%;
z-index:-1;
}
</style>

</head>
<body>
<div id="bgcontainer">
<img id="img" src="image.jpg" alt="" height="100%" width="100%" />
</div>
<div id="content">
hello
</div>
</body>
</html>
 
<html>
<head>
<title>
</title>
</head>
<body>
<img src="image.jpg" alt="" height="100%" width="100%" />
</body>
</html>

Well, for what you want, I do not believe you need any css.
 
Originally posted by: Hyperblaze
<html>
<head>
<title>
</title>
</head>
<body>
<img src="image.jpg" alt="" height="100%" width="100%" />
</body>
</html>

Well, for what you want, I do not believe you need any css.

The css is for allowing content as well, as well as getting rid of margin, scrollbar etc.
 
Back
Top