protected override void OnInit(EventArgs e)
        {
            if (Request["PrecompileOnly"] == "1")
            {
                Response.End();
            }
            if (Sql.IsEmptyString(Application["imageURL"]))
            {
                SplendidInit.InitSession();
            }
            if (AuthenticationRequired())
            {
                if (Sql.IsEmptyGuid(Security.USER_ID))
                {
                    Response.Redirect("~/Users/Login.aspx");
                }
            }

            // 08/30/2005 Paul.  Apply the new culture at the page level so that it is only applied once.
            GetL10n();
            GetT10n();
            GetC10n();
            // 04/30/2006 Paul.  Use the Context to store pointers to the localization objects.
            // This is so that we don't need to require that the page inherits from SplendidPage.
            // A port to DNN prompted this approach.
            Context.Items["L10n"] = GetL10n();
            Context.Items["T10n"] = GetT10n();
            Context.Items["C10n"] = GetC10n();
            base.OnInit(e);
        }
Example #2
0
        protected override void OnInit(EventArgs e)
        {
            if (Request["PrecompileOnly"] == "1")
            {
                Response.End();
            }
            if (Sql.IsEmptyString(Application["imageURL"]))
            {
                SplendidInit.InitSession();
            }
            if (AuthenticationRequired())
            {
                // 11/17/2007 Paul.  New function to determine if user is authenticated.
                if (!Security.IsAuthenticated())
                {
                    Response.Redirect("~/Users/Login.aspx");
                }
            }
            // 11/27/2006 Paul.  We want to show the SQL on the Demo sites, so add a config variable to allow it.
            bDebug = Sql.ToBoolean(Application["CONFIG.show_sql"]);
#if DEBUG
            bDebug = true;
#endif

            // 08/30/2005 Paul.  Apply the new culture at the page level so that it is only applied once.
            GetL10n();
            GetT10n();
            GetC10n();
            // 04/30/2006 Paul.  Use the Context to store pointers to the localization objects.
            // This is so that we don't need to require that the page inherits from SplendidPage.
            // A port to DNN prompted this approach.
            Context.Items["L10n"] = GetL10n();
            Context.Items["T10n"] = GetT10n();
            Context.Items["C10n"] = GetC10n();
            base.OnInit(e);
        }
 protected void Session_Start(Object sender, EventArgs e)
 {
     SplendidInit.InitSession();
 }