ok I have been coding html, php etc for quite some time now.... but always with tables.
I am now forcing myself to learn divs styles etc. So I have been playing around quite a bit and I am having a hard time understanding something.
Does anyone know of a good css reference showing the relationships between operators. ie when an ID vs class is used what the difference between the . # etc are?
I have this page here http://outdoorsindoors.net/DEV/GPAW/...ods/calc/calc1
Just focus from where the gpa calc wizard header is down to the footer. ignore the site header and footer.
html code
styles its usingCode:<div class="calc"> <div id="cbody" class="cbody"> <div id="calchead" class="calchead"></div> <div id="calcname" class="calcname"></div> <div id="calcemail" class="calcemail"></div> <div id="calcstartgp" class="calcstartgp"></div> <div id="calcstarttc" class="calcstarttc"></div> <div id="calcstartqp" class="calcstartqp"></div> <div id="calcfoot" class="calcfoot"></div> </div> </div>
feel free to blast away as I am very new to this and having some trouble. I was under the impression that if I had a div with child divs then the relativity or relationship was to the parent div, nto to the page. If you notice the last 3 css entries the position numbers are higher than I would have expected. I had to put them as that to get them in the relative right location.Code:.calc {background:#FFFFFF; margin: 0;} .calc #cbody{background:#d9e2ff; margin:5px 0px 0px 9px; width:780px; height:500px; } .calc #calchead{ background:url(calc1_header.jpg); text-align:left; width:780px; height:47px;} .calc #calcfoot{ background:url(calc1_foot.jpg); text-align:left; width:780px; height:48px; vertical-align:bottom; position:relative; top:300px;} .calc #calcname{ background:url(calc1_name.jpg); position:relative; text-align:left; width:249px; height:31px;} .calc #calcemail{ background:url(calc1_email.jpg); position:relative; text-align:left; width:249px; height:31px;} .calc #calcstartgp{ background:url(calc1_start_gp.jpg); position:absolute; top: 400px; right: 350px; text-align:left; width:264px; height:26px;} .calc #calcstarttc{ background:url(calc1_start_tc.jpg); position:absolute; top: 425px; right: 350px; text-align:left; width:264px; height:26px;} .calc #calcstartqp{ background:url(calc1_start_qp.jpg); position:absolute; top: 450px; right: 350px; text-align:left; width:264px; height:26px;}
Moving forward this will be a calculator. I will use php to generate numbers that will display over the images for items such as name etc etc. Will I be able to create div elements and have them center or position by px relative to the name div?
any and all help is GREATLY appreciated.
Greg




Reply With Quote


Bookmarks