RYANNNNN
01-02-2008, 04:59 PM
Hey
Here's the code..
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
<style type="text/css">
div#header {
width: 790px;
background: #234374;
height: 100px;
margin-bottom: 20px;
}
div#container {
width: 790px;
margin: auto;
}
div#sidebar {
width: 190px;
margin-right: 20px;
float: left;
background: #4D84BB;
padding: 5px;
}
div#content {
width: 560px;
float: right;
background: #22344A;
padding: 5px;
}
</style>
</head>
<body>
<div id="container">
<div id="header">header</div>
<div id="sidebar">content</div>
<div id="content">stff</div>
</div>
</body>
</html>
It's untested but it should work... basically that's the basics for a layout that can be adapted. It should give you an insight into how to code xhtml/css as well..
For example, the boxes we use the attribute background. It could be changed to say, background: url("images/bg.gif") repeat-x; to create an expanding image background, easy as.
Also, to add a background, in the <style> tags, add ..
body {
background: #hexcode;
}If you need any css help or want to edit this layout or anything related to xhtml/css .. ask here.
Gonna add some more stuff to this thread but ...
If you wanna change the font use:
font: normal 12px arial;
You can change normal to bold or italic or whatever as well as the size. Now, you can either add it in the body styling or a certain div, which means you can have different font styles for different divs.
If you wanna change font color:
color: #hexcode;
Thread moved to tutorials & guides by --ss-- (Forum Super Moderator): Great guide!
Here's the code..
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
<style type="text/css">
div#header {
width: 790px;
background: #234374;
height: 100px;
margin-bottom: 20px;
}
div#container {
width: 790px;
margin: auto;
}
div#sidebar {
width: 190px;
margin-right: 20px;
float: left;
background: #4D84BB;
padding: 5px;
}
div#content {
width: 560px;
float: right;
background: #22344A;
padding: 5px;
}
</style>
</head>
<body>
<div id="container">
<div id="header">header</div>
<div id="sidebar">content</div>
<div id="content">stff</div>
</div>
</body>
</html>
It's untested but it should work... basically that's the basics for a layout that can be adapted. It should give you an insight into how to code xhtml/css as well..
For example, the boxes we use the attribute background. It could be changed to say, background: url("images/bg.gif") repeat-x; to create an expanding image background, easy as.
Also, to add a background, in the <style> tags, add ..
body {
background: #hexcode;
}If you need any css help or want to edit this layout or anything related to xhtml/css .. ask here.
Gonna add some more stuff to this thread but ...
If you wanna change the font use:
font: normal 12px arial;
You can change normal to bold or italic or whatever as well as the size. Now, you can either add it in the body styling or a certain div, which means you can have different font styles for different divs.
If you wanna change font color:
color: #hexcode;
Thread moved to tutorials & guides by --ss-- (Forum Super Moderator): Great guide!