View Full Version : Html input form messing up vertical alignment

05-26-2005, 03:56 AM
The use of this form is making forcing my vertical alignment to the top:


You can see in the second column the search form is on the top, I can't make it go to the middle no-matter what I do, here is the info

The table:

<table class="topbar" border=1>
<tr><td align="left">
<a href="<?php bloginfo('url'); ?>">Home</a> | <a href="general/">General</a> | <a href="Military/">Military</a> | <a href="articles/">Articles</a>
<td align="right">

<form id="searchform" method="get" action="<?php echo $PHP_SELF; ?>"><a>Search</a><input type="text" class="input" name="s" id="search" size="15" onFocus='form.s.value=""'/></form>


Here is my css for class 'topbar'

.topbar {
padding-top: 3px;
padding-left: 5px;
padding-bottom: 3px;
padding-right: 5px;
width: 835px;
height: 17px;
background: #ffffff;
vertical-align: middle;
border-left: 1px solid #ddd;
border-right: 1px solid #ddd;
border-bottom: 1px solid #ddd;
margin-left: 10px;
margin-right: 10px;

I've been troubleshooting this for about an hour now and am totally clueless, I've narrowed it down to the form tag itself because when I take it out it aligns fine and looks how it is suppost to. I don't know why the form is forcing it to align to the top.

Any help would be grrrrrrrrrrrrrrrrrreatly aprecciated,


05-26-2005, 03:59 AM
Man hours? Wow! You might feel a bit silly now. Its the default form margin.
in your css add this

form {

05-26-2005, 04:01 AM
sure do, but at least it works now

thanks a bunch