I am trying to create a kind of grid of divs but i cannot get it to work.
I am a newbie at this and still learning. I have been on many websites but still no luck.
My html is
<div id="pitchdiv" class="dropZoneContainer">
<div id="gk" class="wrapper">
<div id="gk1" class="dropZone" />
</div>
<div id="def" class="wrapper">
<div id="def1" class="dropZone" />
<div id="def2" class="dropZone" />
<div id="def3" class="dropZone" />
<div id="def4" class="dropZone" />
</div>
<div id="mid" class="wrapper">
<div id="mid1" class="dropZone" />
<div id="mid2" class="dropZone" />
<div id="mid3" class="dropZone" />
<div id="mid4" class="dropZone" />
</div>
<div id="str" class="wrapper">
<div id="str1" class="dropZone" />
<div id="str2" class="dropZone" />
</div>
</div>
The CSS is
.wrapper
{
width:380px;
height:148px;
margin-bottom:1px;
margin-top:1px;
border:solid 1px black;
}
.dropZone
{
background-color:Transparent;
height:120px;
width:80px;
float:left;
}
.dropZoneContainer
{
background-image:url(./images/footballpitch2port.png);
top:100px;
left:600px;
height:600px;
width:382px;
position:absolute;
}
When the page is rendered the divs are all over the place really. Im thinking of going back to a table but i would prefer a more flexible solution