Link to home
Start Free TrialLog in
Avatar of vrmetro
vrmetroFlag for United States of America

asked on

List style problem, can not horizontially align

Hello,

Putting together a horizontal list of images, i can get them on one line with a float:left but that doesn't work, i'd like them all aligned center so they have equal spacing inbetween and displays on one line.  Used to be able with a simple align="center" in a TD with no problem...=(  But trying all CSS.  See code below.  This does not horizontally align, but if I add the float:left to #demo ul li, it will, however all images do not fill up one line and a <P> I have below pulls up to fill the gap.  Again, I'd like to have all images equally spaced on one line with out having to define a specific margin between LI's to fill the space... is it possible?
/* Supported Phones Picture Layout */
#demo ul
{
min-width:inherit;
margin:0 0 0 0;
padding:0;
list-style-type:none;
}
 
#demo ul li { 
	display: inline; 
	list-style:none;
}
 
#demo .pics img {  
	padding: 3px;  
    border:  1px solid #ccc;  
	background-color: #f1f1e9; 
	margin-right:1px;
	clear:both;
}
#demo .pics p {
	margin-top:15px;
	text-align: center;
}
 
 
//HTML
            <!-- begin photos -->
            <div id="demo">
            <ul class="pics">
            <li><a title="" href"><img alt="" border="0" src" />
    	   <p>N82</p></a>
            </li>
            <li><a title="" href"><img alt="" border="0" src="" />
    	   <p>N82</p></a>
            </li>
            <li><a title="" href=""><img alt="" border="0" src="" />
    	  <p>N82</p></a>
            </li>
            <li><a title="" href=""><img alt="" border="0" src="" />
    	   <p>N82</p></a>
            </li>
            <li><a title="" href=""><img alt="" border="0" src="" />
    	   <p>N82</p></a>
            </li>
            </ul>
            </div><!-- end photos -->

Open in new window

ASKER CERTIFIED SOLUTION
Avatar of mainemoose
mainemoose
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial