Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Rob Oates 3 posts 73 karma points
    Sep 10, 2020 @ 09:53
    Rob Oates
    0

    Page preview broken when using Umbraco Identity

    Unable to get page preview working whilst using Umbraco 8.5.3 and Umbraco Identity 7.1.0.

    I have even created a vanilla instance of the latest version of Umbraco (8.6.4) and Umbraco Identity (7.1.1) with the starter kit website and previewing is still broken. You are only ever seeing the published version of the page.

  • Yakov Lebski 442 posts 1716 karma points
    Dec 21, 2020 @ 22:03
    Yakov Lebski
    0

    you should add this part to your code

    app
                .UseUmbracoBackOfficeCookieAuthentication(UmbracoContextAccessor, RuntimeState, Services.UserService, GlobalSettings, UmbracoSettings.Security, PipelineStage.Authenticate)
                .UseUmbracoBackOfficeExternalCookieAuthentication(UmbracoContextAccessor, RuntimeState, GlobalSettings, PipelineStage.Authenticate)
                // TODO: this would be considered a breaking change but this must come after all authentication so should be moved within ConfigureMiddleware
                .UseUmbracoPreviewAuthentication(UmbracoContextAccessor, RuntimeState, GlobalSettings, UmbracoSettings.Security, PipelineStage.Authorize);
    
  • Fiona Garnet-Lawson 20 posts 100 karma points
    Apr 06, 2021 @ 13:30
    Fiona Garnet-Lawson
    0

    We have applied this code, but are still unable to preview editorial changes when using Umbraco (8.6.4) and Umbraco Identity (7.1.1). Do you have any other ideas that we can try?

  • Rob Oates 3 posts 73 karma points
    Jan 18, 2021 @ 11:09
    Rob Oates
    0

    Thanks Yakov. The parameter list you have mentioned does not match what I have (Umbraco 8.5.3). In order, the maximum number of parameters for the three methods is 3, 2 and 2 respectively. What version are you using?

    Regards,

    Rob.

  • Rob Oates 3 posts 73 karma points
    Jan 18, 2021 @ 11:44
    Rob Oates
    0

    Ignore my last comment Yakov - I was in the wrong project which was using Umbraco 7.15.3. Am trying it now...

  • Joe Harvey 5 posts 75 karma points
    Sep 24, 2021 @ 09:21
    Joe Harvey
    0

    Rob - Did this work for you in the end?

    If so, can someone advise where (and how much of/which part) this code snippet is intended to be placed in the Umbraco codebase?

Please Sign in or register to post replies

Write your reply to:

Draft