Forum Moderators: not2easy

Message Too Old, No Replies

display image submit button inline

         

atad6

1:37 am on Dec 7, 2007 (gmt 0)

10+ Year Member



i've looked everywhere trying to figure this out. i have a small styled site search form that simply contains a single line text input box and an image submit button. I can't seem to get the submit button to line up with the input box. Without the image, using a standard submit button it works fine, but when I use an image it shifts the input box on the left lower than the submit button. i was able to solve the problem by using a table, but I would like to solve this without. it seems like such a simple problem, what's wrong.

CSS
.search{
background-image:url('search2.gif');
border: none;
width: 198px;
height: 35px;
color: #7cb8e6;
font-size: 9pt;
background-repeat:no-repeat;
padding-left:20px;
margin: 0;
}

html
<input type="text" name="search" class="search">
<input type="image" src="go.gif" >

i simply want the image submit button to display next to the input box on the right, i'm not sure why it's not working, any help would be greatly appreciated

thanks!

Receptional Andy

9:05 pm on Dec 9, 2007 (gmt 0)



It sounds like it might be a space problem. I just copied and pasted the code you posted into a blank document and got an image to the right in both IE and firefox. So perhaps the containing element has enough space for a plain old button but not enough for the image.