Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Brad 94 posts 151 karma points
    Feb 25, 2013 @ 05:47
    Brad
    0

    Styling an asp:LoginView ID="UmbracoLoginView"

    I am using an asp:LoginView ID="UmbracoLoginView" on my site. It looks like this..

    <asp:LoginView ID="UmbracoLoginView" runat="server">
         <AnonymousTemplate>
          <asp:Login ID="Login1" runat="server" CssClass="LoginStyles"></asp:Login>
         </AnonymousTemplate>
         <LoggedInTemplate>
          Welcome
          <asp:LoginName ID="LoginName1" runat="server" CssClass="LoggedInStyles" />
             <asp:LoginStatus ID="LoginStatus1" runat="server" CssClass="LoggedInStyles" />
         </LoggedInTemplate>
    </asp:LoginView>

    The HTML that is produced by this control does not fit the design of the site I am creating. The control spits out a TABLE with rows that each hold 2 cells (td's). 

    I need a layout so the lables are on the row above each textbox.

    Like this..

    <table>
        <tr>
             <td>User Name</td>
        </tr>
        <tr>
              <td><input type='text' id="tUsername". . . . . </td>
         </tr>

    <!-- and so on


      How can I modfiy the default layout of this UmbracoLoginView control?

     

     

     

     

     

     

     

     

     

  • Jan Skovgaard 11280 posts 23678 karma points MVP 12x admin c-trib
    Feb 25, 2013 @ 19:07
    Jan Skovgaard
    0

    Hi Brad

    Isn't what you're after what is already happening above? (My eyes may be bleeding too much to see it properly, though :)).

    Just to make it clear the above is a standard ASP.NET loginView control, which is not related to Umbraco. 

    Are you aware that you could change the layout to be using a nice unordered list instead?

    /Jan

  • Brad 94 posts 151 karma points
    Feb 26, 2013 @ 01:39
    Brad
    0

    No. what is happening above has the 2 tds in each row. so I get this.

    User Name    [<textbox>]

    Password         [<textbox]

    What I need in my design is...

    User Name    

    [<textbox>]

    Password        

    [<textbox]

    Each elemnet in it's own row (<tr>) in

    The code that outputs each of these looks like this..

    <asp:Login ID="Login1"runat="server" CssClass="LoginStyles"></asp:Login>

    It is that line I need to style. Good point however on the fact that this is a .NET control, and not an Umbraco one. I'll take my search for a solution further afield.

     

  • Brad 94 posts 151 karma points
    Feb 26, 2013 @ 01:43
    Brad
    1

    Funny, the first solution I found, was related to Umbraco anyway..

    styling-the-aspnet-login-controls

     

  • Brad 94 posts 151 karma points
    Feb 26, 2013 @ 01:43
    Brad
    0

    (this was a double post)

     

  • Jan Skovgaard 11280 posts 23678 karma points MVP 12x admin c-trib
    Feb 26, 2013 @ 21:18
    Jan Skovgaard
    0

    That Sebastiaan guy...full of good tips! :) - Glad you managed to find a solution to this, thanks for sharing.

    /Jan

  • This forum is in read-only mode while we transition to the new forum.

    You can continue this topic on the new forum by tapping the "Continue discussion" link below.

Please Sign in or register to post replies