css positioning

Discussion in 'CSS' started by gilgalbiblewheel, Sep 20, 2008.

  1. #1
    I don't understand why the three divs don't align properly in a 955px X 580px:
    		<div id="master" style="width: 955px; height: 580px; margin: 0px auto; overflow: hidden;">
    			<div id="title" style="display: none"; >
    				<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" width="955" height="100" id="title" align="middle">
    					<param name="allowScriptAccess" value="sameDomain" />
    					<param name="movie" value="intro/title.swf" />
    					<param name="quality" value="high" />
    					<param name="bgcolor" value="#ffffff" />
    					<embed src="intro/title.swf" quality="high" bgcolor="#ffffff" width="955" height="100" name="title" align="middle" allowscriptaccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />
    				</object>
    			</div>
    			<div id="topnav" style="float: left; width: 955px; height: 60px; background-color:#666666; display: none;">
    			<?php
    				echo "\n<ul style=\"float: left; margin: 0px; font-family: Monotype Corsiva, Verdana, Arial, Helvetica, sans-serif; font-size: 18px; font-weight: bold; list-style-type: none; width: 955px;\">\n"; 
    				$margRL = Array("10px 0px 0px 0px", "10px 0px 0px 40px");
    				
    				$beginning = "<li style=\"float: left; margin: ";
    				$margBreak = "; text-align: center; padding: 0px 0px 15px 0px; border: solid 1px #BCB2B3; background-color: #F6F5E3; width:"; 
    				$width= "190";
    				$andThen= "px; height: 25px;\">\n\t<a href=\"";
    				
    				/***************************Functions********************************************/
    				$theAnchors = Array("index", "gallery", "music", "prose", "contact");
    				/********************************************************************************/
    				
    				$continue = ".php\" style=\"text-decoration: none; color: #000000; display: block;\" onmouseover=\"this.style.color='#FFFFFF'; this.style.backgroundColor='#BCB2B3';\" onmouseout=\"this.style.color='#000000'; this.style.backgroundColor='#F6F5E3';\" onclick=\"this.style.backgroundColor='#666666'; this.style.color='#FFFFFF';\">\n\t\t<span style=\"display: block; padding: 4px 10px 0px 10px;\">";
    				$names = Array("Home", "Gallery", "Music", "Prose", "Contact");
    				$ending = "</span>\n\t</a>\n</li>";
    					for($i = 0; $i < count($names); $i++){
    						if($i!== 2){
    							if($i== 0){
    								echo $beginning.$margRL[0].$margBreak.$width.$andThen.$theAnchors[$i].$continue.$names[$i].$ending."\n";
    							}else{
    								echo $beginning.$margRL[1].$margBreak.$width.$andThen.$theAnchors[$i].$continue.$names[$i].$ending."\n";
    							}			
    						}
    					}
    				echo "</ul>";
    			?>
    			</div>
    			<div id="content" style="margin: 70px 0px 0px 0px;">
    <div id="blog" style="float: right; margin: 0px 0px 0px 10px; background-color: #666666; width: 645px; height: 510px;">
    					<form name="blogcheck" id="blogcheck" action="" method="post" style="float: left;">
    						<span id="blog_title" style="margin: 0px 0px 0px 10px; font-family: Alba, Verdana, Arial, Times New Roman; color: #ffffff; font-size: 24px; display: block; width: 100px;">My Blog</span>
    						<select id="month" name="month" style="margin: 0px 0px 0px 10px; ">
    							<option selected="selected">Select a Month</option>
    							<?php
    							$month = array("January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "Novemeber", "December");
    							$k = 1;
    							for($j=0; $j<count($month); $j++){
    							  echo "<option value=\"".$k."\">".$month[$j]."</option>\n\t\t\t\t\t\t";
    							  $k++;
    							}
    							?>
    	
    						</select>
    						<input style="" alt="Year" id="year" name="year" value="2008" title="Enter year in this field (4 digits) " size="5" /><br />
    						<div id="blog_text" style="margin: 0px 0px 0px 10px; background-color: #BCB2B3; width: 350px; height: 390px; overflow-x: none; overflow-y: auto;">
    							<?php include("blog.php"); ?>
    						</div>
    					</form>
    				</div>
    				<div id="whitecontainer" style="margin: 10px 0px 0px 0px; padding: 10px; background-color: #ffffff; width: 300px; height: 510px;">
    					<div id="picture" style="background-color: #BCB2B3; width: 280px; height: 180px;">
    					  <?php /*<img  style="" src="images/sized_n515436027_322100_6943.jpg" border="none" alt="Andrew Da Silva" width="126" height="168" />*/ ?>
    					</div>
    					<?php
    					/*
    					<div id="bio" style="margin: 10px 0px 0px 10px; background-color: #666666; width: 280px; height: 310px;">
    						<span id="biotitle" style="margin: 10px 0px 0px 10px; font-family: Alba, Verdana, Arial, Times New Roman; color: #ffffff; font-size: 24px; height: 30px;">Biography</span> 
    						<span id="biotext" style="margin: 10px 0px 10px 10px; width: 248px; height: 180px; padding: 0px 5px 0px 5px; overflow-y: auto; font-family: Verdana, Arial, Times New Roman; color: #000000; font-size: 12px; background-color: #BCB2B3; display: block;">
    							<span style="font-weight: bold;">Andrew Da Silva</span> is an aspiring artist, writer from Montreal Quebec. With a strong belief in doing something different, he fuses elements of cartooning, comic books, pop culture, music, and film, into his works of art. Visions of shapes, colors, words, women, and just about any carnal thoughts a man may have occupy his mind. When he is not loafing around playing Playstation, or watching YouTube, Andrew will attempt to draw or write. This usually results in lazy sketches, or words on a page that somehow form into complete works of art. Andrew loves booze, Hip-Hop, video games, and clothing. Some people may call Andrew a nerd, and this is alright with him. Andrew does not like writing Bio's in third person about himself. He thinks that it's wack, and would now like to leave this bio, while you indulge in the privilege of browsing his website.</span> 
    					</div>
    					*/
    					?>
    				</div>
    			</div>
    		</div
    PHP:
    http://205.205.200.231/~h806209/indexAndr.php
     
    gilgalbiblewheel, Sep 20, 2008 IP