View Full Version : div box

10-10-2006, 12:12 PM

i am trying to create a box using the div tag, the boex needs to be 300px width and 200 px in height, it also needs a header section, and two columns below, the left column for text and the right to hold a small picture in tyhe centre.

can anyone help,

not worried about styling or anything yet, just an outline of the section would be great.

thanks in advance.

10-10-2006, 09:18 PM
This should get you started:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Untitled Document</title>

<style type="text/css">
#container {
width: 300px;
height: 200px;
min-height: 200px;
border: 2px solid #000;
margin: auto;

#side {
float: left;
width: 195px;

#content {
float: left;
width: 95px;

h1 {
text-align: center;

<div id="container">
<h1>This would be the header</h1>
<div id="side">
<p>Add your text here</p>
<div id="content">
<p>Add your image here</p>