Reply
how to get rid of space in forms
Old 07-19-2004, 11:30 AM how to get rid of space in forms
TicK's Avatar
Average Talker

Posts: 16
What's the property that controls the space between the button and the textbox (red arrow)...I tried margin and padding. No luck...



Code:
<form action=\"index.php\" method=\"post\">
<h2 class=\"sidebar-title\">Search</h2>
<input type=text name=search id=\"searchBox\" size=15>
<input type=submit value=\"GO!\" id=\"searchButton\">
</form>
TicK is offline
Reply With Quote
View Public Profile
 
When You Register, These Ads Go Away!
Old 07-19-2004, 11:52 AM
Republikin's Avatar
Super Moderator

Posts: 3,191
Try putting the form in a table and putting each element in its own cell.
Republikin is offline
Reply With Quote
View Public Profile
 
Old 07-19-2004, 12:21 PM
Christopher's Avatar
Iced Cap

Posts: 3,111
Location: Toronto, Ontario
A margin of 0 should do the trick. Make sure there's no spaces after the text box and before the button and try putting them on the same line.

This is what I got.

HTML Code:
<input type="text" style="margin:0" /><input type="button" value="Go" style="margin:0;border: 1px solid black" />
Attached Images
File Type: gif untitled.GIF (1.5 KB, 17 views)
Christopher is offline
Reply With Quote
View Public Profile Visit Christopher's homepage!
 
Old 07-19-2004, 12:41 PM hi
Mooofasa's Avatar
Defies a Status

Posts: 1,612
Name: Michael (mik) Land
Location: England
you can also increase the space by puttin :&nbsp between the two parts. :&nbsp is just some kind of stupid code that means space. It helps when using it in graphical and form elements.

just ignore what i just put (" you can also ince...") i thought you said increase space. My bad.



Mik

Last edited by Mooofasa : 07-20-2004 at 07:25 AM.
Mooofasa is offline
Reply With Quote
View Public Profile Visit Mooofasa's homepage!
 
Old 07-19-2004, 12:42 PM hi
Mooofasa's Avatar
Defies a Status

Posts: 1,612
Name: Michael (mik) Land
Location: England
instead of a table you can put it into <div>, </div> tags. It is much easier and usable than table tags.
Mooofasa is offline
Reply With Quote
View Public Profile Visit Mooofasa's homepage!
 
Old 07-19-2004, 12:53 PM
TicK's Avatar
Average Talker

Posts: 16
Quote:
Originally Posted by Chroder
A margin of 0 should do the trick. Make sure there's no spaces after the text box and before the button and try putting them on the same line.

This is what I got.

HTML Code:
<input type="text" style="margin:0" /><input type="button" value="Go" style="margin:0;border: 1px solid black" />
ahh..excellent thanks didn't know it reads in the spaces. Fixed now.
TicK is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to how to get rid of space in forms
 

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off




   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML

 


Page generated in 0.13650 seconds with 13 queries