I am trying to center the login control that shows after selecting login using the loginstatus control.
<div id="linkContent">
<asp:LoginStatus ID="LoginStatus2" runat="server"
LogoutAction="RedirectToLoginPage" />
</div>
I have tried a couple different methods that I found on google and none are working. I am using IE 9.
I tried:
#linkContent
{
text-align: center;
}
I have tried:
<div id="linkContent">
<asp:LoginStatus ID="LoginStatus2" runat="server"
LogoutAction="RedirectToLoginPage" style="text-align: center;" />
</div>
and I tried:
#linkContent
{
margin-left:auto;
margin-right:auto;
}
I also pointed login to my own Login.aspx but it doesn't work either:
in webconfig:
<authentication mode="Forms" >
<forms loginUrl="Login.aspx" />
</authentication>
None of these have worked. The login control stays left aligned. The loginStatus control is used within a master page.
Any help would be appreciated.
Thanks.
Using inline style (move it to your CSS file!) :
Change 500px to the width of your control.