Reputation: 3
I have the code below
<li class="ui-body ui-body-b">
<fieldset class="ui-grid-a">
<div class="ui-grid-solo"><button id="btn1" type="submit" >Submit</button></div>
</fieldset>
</li>
if i am using this the button is not center.. how place it in center
Upvotes: 0
Views: 11536
Reputation: 7207
I dont have idea about your css code. generally, to align some element in center you can use something like this
CSS:
div.center{
margin:0 auto;
display:block;
text-align:center;
}
HTML:
<div class="ui-grid-solo center"><button id="btn1" type="submit" >Submit</button></div>
Upvotes: 2
Reputation: 11310
Here is the Fiddle.
Just add the following code in your css.
button{
position: relative;
left: 50%;
}
Upvotes: 2
Reputation: 2622
I have found using text-align in css will work:
.ui-grid-solo { text-align:center; }
Upvotes: 0