예제 #1
0
        private WebForm SetupOptionsPage(string page_url, string action_url)
        {
            WebPage optionspage = new WebPage("Options");

            this.VFileSystem.Root.PutFile(page_url, optionspage);
            optionspage.AddCSS("control.css");

            WebHeader optionsheader = new WebHeader(1, "Options");

            optionspage.Children.Add(optionsheader);

            WebForm options_form = new WebForm("options", action_url);

            optionspage.Children.Add(options_form);

            return(options_form);
        }
예제 #2
0
        private WebForm AuthSetupLoginPage(string page_url, string action_url)
        {
            WebPage loginpage = new WebPage("Login");

            this.VFileSystem.Root.PutFile(page_url, loginpage);
            loginpage.AddCSS("control.css");

            WebHeader loginheader = new WebHeader(1, "Login");

            loginpage.Children.Add(loginheader);

            WebForm login_form = new WebForm("login", action_url);

            login_form.Children.Add(new WebDiv("username_wrapper", "login_wrapper", new WebTextInput("username", "User")));
            login_form.Children.Add(new WebDiv("password_wrapper", "login_wrapper", new WebPasswordInput("password", "Password")));
            login_form.Children.Add(new WebDiv("submit_wrapper", "login_wrapper", new WebSubmit("submit", "Submit", null)));
            loginpage.Children.Add(login_form);

            return(login_form);
        }