I have a asp:Panel where Grouping text is equal to "string".Now this string comes on the left hand side on the upper half of panel border.I want this grouping text to come in the center as in a title of the panel.How can we do this
A:
You can move it to the right using css. Although I don't know of a way to have it automatically centered.
Target it by using legend {margin-left:<px>;}
mjw06d
2010-09-15 13:35:14
Beautiful works...I was trying using position absolute.That too does the job.Thanks
gizgok
2010-09-15 13:42:36
margin: 0 auto doesn't work, that was the first property I tested. But if, in the future you use margin: 0 auto, you need to define a width as well.
mjw06d
2010-09-15 14:11:03