I have a problem in which I have a space between these two buttons.
The code is as follows:
<input id="NeedBtn" class="PostBtn" type="button" /> <input id="ProvBtn" class="PostBtn" type="button" /> .PostBtn { background: url(../Images/Buttons/PostButtonF.png) no-repeat; width: 50px; height: 28px; border: none; margin: 0; padding: 0; } #NeedBtn { background-position: 0 0; } #ProvBtn { background-position: -50px 0; }
How do I remove that space?
Browser: Firefox 3.5
IE8
The simplest way to add a space in HTML (besides hitting the spacebar) is with the non-breaking space entity, written as or  . Multiple adjacent non-breaking spaces won't be collapsed by the browser, letting you “force” several visible spaces between words or other page elements.
You can add more space between a button and text box by using “margin” attribute. If you want to add right side more space then add “margin- right”, for left side “magin-left”, for top side “margin-top”, for bottom “margin-bottom”.
The line feed between the two <input>
s creates a space between them on the page. You have to remove the line feed, or use this trick :
<input id="NeedBtn" class="PostBtn" type="button" /><!-- --><input id="ProvBtn" class="PostBtn" type="button" />
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With