protected void loadData() { var BadSSL = CommonLogic.QueryStringBool("BadSSL"); if (BadSSL) { ctrlAlertMessage.PushAlertMessage(AppLogic.GetString("admin.wizard.BadSSL", ThisCustomer.LocaleSetting), AlertMessage.AlertType.Error); } BuildPaymentMethodList(AppLogic.AppConfig("PaymentMethods", 0, false)); if (AppLogic.TrustLevel == AspNetHostingPermissionLevel.Unrestricted) { var webconfig = WebConfigurationManager.OpenWebConfiguration(Request.ApplicationPath); var appsettings = (AppSettingsSection)webconfig.GetSection("appSettings"); var connectionStrings = (ConnectionStringsSection)webconfig.GetSection("connectionStrings"); rblEncrypt.Items.FindByValue((appsettings.SectionInformation.IsProtected && connectionStrings.SectionInformation.IsProtected).ToString().ToLowerInvariant()).Selected = true; var mkeysec = (MachineKeySection)webconfig.GetSection("system.web/machineKey"); if (mkeysec.ValidationKey.Equals("autogenerate", StringComparison.InvariantCultureIgnoreCase)) { rblStaticMachineKey.Items.FindByValue("false").Selected = true; ltStaticMachineKey.Text = AppLogic.GetString("admin.wizard.SetStaticMachineKey", ThisCustomer.SkinID, ThisCustomer.LocaleSetting); } else { rblStaticMachineKey.Items.FindByValue("false").Selected = true; ltStaticMachineKey.Text = AppLogic.GetString("admin.wizard.ChangeStaticMachineKey", ThisCustomer.SkinID, ThisCustomer.LocaleSetting); } } switch (BuySafeController.GetBuySafeState()) { case BuySafeState.NotEnabledFreeTrialAvailable: break; case BuySafeState.EnabledFullUserAfterFreeTrial: case BuySafeState.EnabledOnFreeTrial: pnlBuySafeActive.Visible = true; pnlBuySafeInactive.Visible = false; litBuySafeActiveMsg.Text = "buySAFE is enabled"; break; case BuySafeState.EnabledFreeTrialExpired: case BuySafeState.NotEnabledFreeTrialExpired: pnlBuySafeActive.Visible = true; pnlBuySafeInactive.Visible = false; litBuySafeActiveMsg.Text = "<span style='line-height:normal;'>Trial expired. Please contact buySAFE to enable your account.<br />Call 1.888.926.6333 | Email: <a href='mailto:[email protected]'>[email protected]</a></span>"; break; case BuySafeState.Error: pnlBuySafeActive.Visible = true; pnlBuySafeInactive.Visible = false; litBuySafeActiveMsg.Text = "<span style='line-height:normal;'>Please contact buySAFE to enable your account.<br />Call 1.888.926.6333 | Email: <a href='mailto:[email protected]'>[email protected]</a></span>"; break; } }
private void ChooseInitialDisplay() { SetPageState(BuySafeController.GetBuySafeState()); }
protected void loadData() { bool BadSSL = CommonLogic.QueryStringBool("BadSSL"); if (BadSSL) { resetError("No SSL certificate was found on your site. Please check with your hosting company! You must be able to invoke your store site using https:// before turning SSL on in this admin site!", false); } String PM = AppLogic.AppConfig("PaymentMethods", 0, false).ToUpperInvariant(); BuildPaymentMethodList(PM); if (AppLogic.TrustLevel == AspNetHostingPermissionLevel.Unrestricted) { Configuration webconfig = WebConfigurationManager.OpenWebConfiguration(Request.ApplicationPath); AppSettingsSection appsettings = (AppSettingsSection)webconfig.GetSection("appSettings"); rblEncrypt.Items.FindByValue(appsettings.SectionInformation.IsProtected.ToString().ToLowerInvariant()).Selected = true; MachineKeySection mkeysec = (MachineKeySection)webconfig.GetSection("system.web/machineKey"); if (mkeysec.ValidationKey.Equals("autogenerate", StringComparison.InvariantCultureIgnoreCase)) { rblStaticMachineKey.Items.FindByValue("false").Selected = true; ltStaticMachineKey.Text = AppLogic.GetString("admin.wizard.SetStaticMachineKey", ThisCustomer.SkinID, ThisCustomer.LocaleSetting); } else { rblStaticMachineKey.Items.FindByValue("false").Selected = true; ltStaticMachineKey.Text = AppLogic.GetString("admin.wizard.ChangeStaticMachineKey", ThisCustomer.SkinID, ThisCustomer.LocaleSetting); } } switch (BuySafeController.GetBuySafeState()) { case BuySafeState.NotEnabledFreeTrialAvailible: break; case BuySafeState.EnabledFullUserAfterFreeTrial: case BuySafeState.EnabledOnFreeTrial: pnlBuySafeActive.Visible = true; pnlBuySafeInactive.Visible = false; litBuySafeActiveMsg.Text = "buySAFE is enabled"; break; case BuySafeState.EnabledFreeTrialExpired: case BuySafeState.NotEnabledFreeTrialExpired: pnlBuySafeActive.Visible = true; pnlBuySafeInactive.Visible = false; litBuySafeActiveMsg.Text = "<span style=\"line-height:normal;\">Trial expired. Please contact buySAFE to enable your account.<br />Call 1.888.926.6333 | Email: <a href=\"mailto:[email protected]\">[email protected]</a></span>"; break; case BuySafeState.Error: pnlBuySafeActive.Visible = true; pnlBuySafeInactive.Visible = false; litBuySafeActiveMsg.Text = "<span style=\"line-height:normal;\">Please contact buySAFE to enable your account.<br />Call 1.888.926.6333 | Email: <a href=\"mailto:[email protected]\">[email protected]</a></span>"; break; } }