Log in

View Full Version : How to create a border around this site



staynfly
12-05-2008, 02:40 PM
Hi, please help, I want to create a 20px border of red color from all the four sides of www.staynfly.com (http://www.staynfly.com).

Can I also have some shadow effect to the border as well.

Shall be grateful. Sorry for my ignorance.

boogyman
12-05-2008, 02:59 PM
my suggestion would not to use the border properties, however create background image with the affect you are looking for and assign it to the body, making sure to provide an html color similar to the primary color of the image in-case the image for some reason doesn't show up



body {
background: #hexadecimal url('/path/to/image.ext');
}


than have a containing element for the content, and apply some the appropriate margin you wish to achieve, and assign a background color to distinguish the element from the desired body background.



<body>

<div id="container">
<!-- body content here -->
</div>

</body>




div#container {
margin: 20px;
background-color: #ffffff; /* hexadecimal for white */
}

Snookerman
12-05-2008, 03:01 PM
Add this to your .css:

html {
border: solid 20px #ff0000;
}