Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics CRM (Archived)

Adx portal 7.0.0023 Sign In pages is absent

Posted on by 390

Hi guys,

Just implemented authentication based navigation menu (using liquid templates) for latest Adxportal version and found that "Sign In" link doesn't work.

Investigation show than recommended by Adx sitemarker "Login" does not exist anymore and the follow row returns null:

href="{{ sitemarkers['Login'].url | add_query:'returnurl', request.path_and_query }}"

Not a problem. Let's create the Login sitemarker and reference Sign In page. Oops. There is no more Sign In page and mvc controller figures out the sign in url  based on used context and redirects it to different type of Sign In controllers.

If you're planning to go online and want to stick with liquid templates then the fast work around is to change it for Profile site marker. It will always redirect not authenticated user to Sign In page:

href="{{ sitemarkers['Profile'].url | add_query:'returnurl', request.path_and_query }}"

Does any body know how to fetch Sign In url with liquid templates  ?

 

 

 

 

 

*This post is locked for comments

  • Micchael Profile Picture
    Micchael 390 on at
    RE: Adx portal 7.0.0023 Sign In pages is absent

    Thank you guys

  • Verified answer
    Colin V Profile Picture
    Colin V on at
    RE: Adx portal 7.0.0023 Sign In pages is absent

    Just to add to Nick's solution if you want to maintain the functionality of the proper return URL there is a liquid attribute in the request object you can use - ?returnUrl={{ request.raw_url_encode }}

  • Verified answer
    Nick.Doelman Profile Picture
    Nick.Doelman 1,947 Most Valuable Professional on at
    RE: Adx portal 7.0.0023 Sign In pages is absent

    I ran into the same issue, it's a clunky solution but it works

    At the start of the web template record:

    {% assign signin_url = '~\SignIn?returnUrl=%2F' %}

    {% assign signout_url = '~\Account\Login\Logoff?returnUrl=%2F' %}

    {% assign signup_url = '~\sign-up' %}

    and later in the code (depending on where/how you want the buttons):

    <a href="{{ signout_url | escape }}" class="btn btn-block btn-lg btn-primary">{{ snippets["signout"] }}</a>

    Cheers

    Nick

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,269 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,198 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans