From d8cd2c109f8f346df554dd84b077a82fbdd9c1e1 Mon Sep 17 00:00:00 2001 From: Sebastiaan Janssen Date: Fri, 31 Aug 2018 21:07:32 +0200 Subject: [PATCH] Merge branch 'feature/remove-logout-aspx' of https://github.com/imranhaidercogworks/Umbraco-CMS into imranhaidercogworks-feature/remove-logout-aspx # Conflicts: # src/Umbraco.Web.UI/umbraco_client/Application/UmbracoApplicationActions.js --- src/Umbraco.Web.UI/Umbraco.Web.UI.csproj | 1 - src/Umbraco.Web.UI/Umbraco/Logout.aspx | 42 ------------------- .../UI/Pages/UmbracoEnsuredPage.cs | 10 ++--- 3 files changed, 5 insertions(+), 48 deletions(-) delete mode 100644 src/Umbraco.Web.UI/Umbraco/Logout.aspx diff --git a/src/Umbraco.Web.UI/Umbraco.Web.UI.csproj b/src/Umbraco.Web.UI/Umbraco.Web.UI.csproj index 08bee948ee..f5e9af6200 100644 --- a/src/Umbraco.Web.UI/Umbraco.Web.UI.csproj +++ b/src/Umbraco.Web.UI/Umbraco.Web.UI.csproj @@ -232,7 +232,6 @@ - umbraco.aspx diff --git a/src/Umbraco.Web.UI/Umbraco/Logout.aspx b/src/Umbraco.Web.UI/Umbraco/Logout.aspx deleted file mode 100644 index 84f12f03a6..0000000000 --- a/src/Umbraco.Web.UI/Umbraco/Logout.aspx +++ /dev/null @@ -1,42 +0,0 @@ -<%@ Page Language="C#" %> -<%@ Import Namespace="Umbraco.Core" %> -<%@ Import Namespace="Umbraco.Core.IO" %> -<%@ Import Namespace="Umbraco.Web" %> - - - - - - - - Logout - - - - - diff --git a/src/Umbraco.Web/UI/Pages/UmbracoEnsuredPage.cs b/src/Umbraco.Web/UI/Pages/UmbracoEnsuredPage.cs index a8cb93c704..30adf2cc3d 100644 --- a/src/Umbraco.Web/UI/Pages/UmbracoEnsuredPage.cs +++ b/src/Umbraco.Web/UI/Pages/UmbracoEnsuredPage.cs @@ -112,11 +112,11 @@ namespace Umbraco.Web.UI.Pages // Clear content as .NET transfers rendered content. Response.Clear(); - // Some umbraco pages should not be loaded on timeout, but instead reload the main application in the top window. Like the treeview for instance - if (RedirectToUmbraco) - Response.Redirect(SystemDirectories.Umbraco + "/logout.aspx?t=" + Security.GetSessionId(), true); - else - Response.Redirect(SystemDirectories.Umbraco + "/logout.aspx?redir=" + Server.UrlEncode(Request.RawUrl) + "&t=" + Security.GetSessionId(), true); + // Ensure the person is definitely logged out + UmbracoContext.Current.Security.ClearCurrentLogin(); + + // Redirect to the login page + Response.Redirect(SystemDirectories.Umbraco + "#/login", true); } }