Example #1
0
        public LoginForm()
        {
            this.Action  = "/login";
            Method       = "POST";
            AutoComplete = "off";
            Classes      = new[] { "form-stacked" };

            DefineFields <LoginModel>(f =>
            {
                f.AddField(x => x.Username);
                f.AddField(x => x.Password);
            });

            SubmitButton
            .AddClass("btn-primary")
            .Text("Login");

            SecondaryLinks.Add(new HtmlTag("a").Text("Forgot Password?").Attr("href", "/recover"));
        }