2 replies [Last post]
tippaflorda
tippaflorda's picture
Offline
newbie
Orange County, CA
Last seen: 12 years 47 weeks ago
Orange County, CA
Timezone: GMT-8
Joined: 2009-08-28
Posts: 8
Points: 9

Hello there:

I have a simple issue with alignment and centering that I would be grateful for suggestions. In safari and Firefox,
I would like the thing to align in the center of the page, to drag out with browser and collapse with browser. Thanks much in advance for any help!

<!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>
<title>Wilson Vision</title>
<style type="text/css">
body {
	background-color: #CCCCCC;
	text-align:center;
	font-family:Arial, Helvetica, sans-serif;
	font-size:76%;
 
 
}
 
* {
	margin: 0px;
}
 
 
ul {
	margin-left: 0px;
	margin-top: 0px;
	}
 
li {
	font-size: 12px;
	font-weight: normal;
	text-transform: uppercase;
	color: #FFFFFF;
	float:left;
	width: 115px;
	list-style: none;
	font-family: Verdana, Arial, Helvetica, sans-serif;
	text-align:center;
	font-style: normal;
	text-decoration: none;
}
 
a:link {
	text-decoration: none;
	color: #ffffff;
}
a:visited {
	text-decoration: none;
	color:#3399CC;
 
}
a:hover {
	text-decoration: none;
}
a:active {
	text-decoration: none;
}
 
.nolink {
	text-decoration: none;
	font-size: 12px;
	font-weight: normal;
	text-transform: uppercase;
	color:#3399CC;
	float: left;
	width: 100px;
	list-style: none;
	font-family: Verdana, Arial, Helvetica, sans-serif;
	text-align:center;
}
 
 
.center
{
margin-left:auto;
margin-right:auto;
width:70%;
 
}
 
 
#colcontain {
 
 heigth:100px;
padding: 2px 2px 10px 2px;
 
}
 
#logo { 
 
 
	   margin:0px; 
	   border:0px;  
	   float:left;
	   width:auto;
	    } 
 
 
#topnav {
 
}
container {
float:left;}
</style>
</head>
 
 
<body>
 
 
 <div id="center">
 
<div id="colcontain">
	<div id="logo"><a href="index.html"><img src="images/wilson.gif"/></a></div>
	<div id="topnav">
 
    <ul>	
        <li><a href="photography.html">photography</a></li>
        <li><a href="wedding.html">weddings</a></li>
        <li><a href="webdesign">web design</a></li>
        <li><a href="journalism.html">journalism</a></li>
    </ul>
 
</div>
</div></div>
<div id ="container"><img src="images/sky800.jpg"/> </div>
 
<ul>
	<li><a href="about.html">About</a></li>
    <li><a href="http://www.wilsonvision.com/blog" target="_blank" class="nolink">Blog</a></li>
  <li><a href="contact.html">Contact</a></li>
 
</ul>
 
</div>
<div>
	<h1>2009 &copy;wilson vision</h1>
 
 
</div>
 
</body>
</html>

wolfcry911
wolfcry911's picture
Offline
Guru
MA, USA
Last seen: 8 years 49 weeks ago
MA, USA
Timezone: GMT-5
Joined: 2004-09-01
Posts: 3224
Points: 237

you've classed center in css

you've classed center in css but given it an id in the html

tippaflorda
tippaflorda's picture
Offline
newbie
Orange County, CA
Last seen: 12 years 47 weeks ago
Orange County, CA
Timezone: GMT-8
Joined: 2009-08-28
Posts: 8
Points: 9

Thanks much for your help.

Thanks much for your help. Sorry for delay in expressing that.