Example #1
0
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                // Set the selected menu item in Master page.
                Master.TheMenuInMasterPage.SelectedItem = "login";

                Tries = 0;

                // Put cursor in first field
                TextboxUserName.Focus();
            }
        }
Example #2
0
        protected void Page_Load(object sender, EventArgs e)
        {
            // Meta data: helpful for SEO (search engine optimization)
            Page.Title           = "Login";
            Page.MetaKeywords    = "Login, Administration";
            Page.MetaDescription = "Login to Administrative Area in Patterns in Action";

            if (!IsPostBack)
            {
                // Set the selected menu item in Master page.
                SelectedMenu = "login";

                Tries = 0;

                // Put cursor in first field
                TextboxUserName.Focus();
            }
        }