View Full Version : text-align with a button
Isn't there some way to align the button value to the left, without that annoying horizontal padding?
I can destroy the vertical padding with "line-height", but cannot find a way to do the same with the width. :confused:
The problem is that the width of the button is reduced from the right, which leaves padding to the left of the button text.
Is there something similar to line-height that I could apply to the horizontal, or no?
justame
02-17-2003, 05:29 PM
swm...
just a welcome® to the forum...:O)))
n' have ya just a considered® using just a image® for the 'button'??? fully customizable thennn :O)))
just a suggestion®...goodluck...
Right, thanks... it just bugs me that buttons are so stubborn! ;)
Catman
02-17-2003, 06:11 PM
This works in both IE 6 and Netscape 7.0:
<html>
<head>
<title>Button Test</title>
<style>
button {
width : 20em;
}
span {
float : left;
}
</style>
</head>
<body>
<button type="button"><span>This is My Button</span></button>
</body>
</head>
I'm against using images for such things when a workable HTML/CSS solution exists.
justame
02-17-2003, 06:55 PM
Originally posted by Catman
This works in both IE 6 and Netscape 7.0:
I'm against using images for such things when a workable HTML/CSS solution exists.
/me is just a tooo®...'cept sometimes??? to just a please® the client??? ya gotta do what ya gotta do...n' @ the time??? thattt just a did® the job...lol...
n' since thattt was just a few® 'years' back??? /me nowww has yourrr coding copied/pasted/credited/saved for the 'most commonly used' browsers...:O)))
just a ta® for sharing...:O)))
That's a good trick. Thanks for the example. :cool:
vBulletin® v3.8.2, Copyright ©2000-2012, Jelsoft Enterprises Ltd.