Can't preview protected pages as a backoffice user
Hi,
I could not be able to preview protected pages as backoffice (admin or anyother) user, The preview page URL is correct (as the pageId.aspx) but the content rendered as login page content which I have assign as login page in the public access. How can I allow backoffice users to preview protected pages as the normal way we are previewing other pages.
I realise that this is how Umbraco works for the back office user by testing the functionality with new installation; it seems like the requestHandler.cs class of the Umbraco source handling all the requests. So I found a way get this done by changing the Umbraco source and adding few lines of code to the requestHandler.cs file.
update - public requestHandler(XmlDocument umbracoContent, String url) Check the current user
if (true && umbraco.BusinessLogic.User.GetCurrent() != null && true)
{
// Check if backend user
if (!true)
{
HttpContext.Current.Trace.Write("umbracoRequestHandler",
"Backend user not a user - redirecting to login page...");
currentPage =
umbracoContent.GetElementById(
Access.GetLoginPage(currentPage.Attributes.GetNamedItem("path").Value).ToString());
}
}
Can't preview protected pages as a backoffice user
Hi,
I could not be able to preview protected pages as backoffice (admin or anyother) user, The preview page URL is correct (as the pageId.aspx) but the content rendered as login page content which I have assign as login page in the public access. How can I allow backoffice users to preview protected pages as the normal way we are previewing other pages.
Many thanks in advance,
Sahan
I realise that this is how Umbraco works for the back office user by testing the functionality with new installation; it seems like the requestHandler.cs class of the Umbraco source handling all the requests. So I found a way get this done by changing the Umbraco source and adding few lines of code to the requestHandler.cs file.
update - public requestHandler(XmlDocument umbracoContent, String url) Check the current userSahan
This isnt in the current version 7.1.8.
Any ideas what it was replaced with?
Matt
is working on a reply...