css formatting legend

M

mark | r

hi have a form using <legend> the content of which is indented about 10px
from the left
how can i re-style this to be flush with the form contents?

mark
 
M

Mitja

Use css:
put something like this in you <head> section:
<style type="text/css">
legend {
margin-left: 0px;
text-indent: 0px;
}
</style>
 
M

mark | r

thanks but it didnt work :(

mark
Mitja said:
Use css:
put something like this in you <head> section:
<style type="text/css">
legend {
margin-left: 0px;
text-indent: 0px;
}
</style>
 
E

Ethan Schlenker

On 2004-01-30 08:15:07 -0800, "Mitja" <[email protected]> said:
Use css:
put something like this in you <head> section:
<style type="text/css">
legend {
margin-left: 0px;
text-indent: 0px;
}
</style>

Almost. The issue is that legend's have a built in 'buffer'. And the buffer
isn't really 10 pixels. It's more like .7em So if you change the css to :

legend {
margin-left: -.7em;
text-indent: 0px; /* I'm not really sure this line is necessary */
}

It'll look the way you want it, even if the user resizes their text.
Probably.


Ethan
 
M

Mark Parnell

hi have a form using <legend> the content of which is indented about 10px
from the left
how can i re-style this to be flush with the form contents?

In your CSS:

legend {margin: 0;
padding: 0; }
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top