web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id : w7Pl037MPxmWxWxlBR/Gid
Power Pages - Power Apps Portals
Unanswered

Hide Web Link based on Web Role

Like (0) ShareShare
ReportReport
Posted on 11 Feb 2022 09:25:06 by

Hello Community,

 

On the Power Apps Portal, if I have a web link which contains no pages - so in other words just serving as a menu without pages associated to it, is there a way to hide the web link based on the web role or other permissions? I couldn't seem to find any settings where I can do this through configuration. Again, I am not using the web page access control rules because it's not the web page I am trying to restrict here, it's simply the web link, and it's for web link that doesn't contain any web pages.

 

Would appreciate some pointers.

 

Thank you!

  • Community Power Platform Member Profile Picture
    on 11 Feb 2022 at 15:36:22
    Re: Hide Web Link based on Web Role

    Thank you @chleverenz , @ragavanrajan  for sharing the insights!

  • ragavanrajan Profile Picture
    7,036 Most Valuable Professional on 11 Feb 2022 at 09:40:37
    Re: Hide Web Link based on Web Role

    The approach from @chleverenz is also feasible. Good learning for liquid and JavaScript. 

     

    Give us a shot if you are struck. 

     

    Cheers 

    Ragavan 

  • ragavanrajan Profile Picture
    7,036 Most Valuable Professional on 11 Feb 2022 at 09:36:34
    Re: Hide Web Link based on Web Role

    Hi @Anonymous 

     

    We have done this in one of our project. 

    The approach was 

     

    In Portal studio: 

     

    1. Create a webpage ex: Test Form.

    In portal management:

    1. Edit the default link web set and find the newly created page.

    2. Add your external url or link 

    3. Then apply web page access control rule as usual 

    4. Apply web roles on top of it. 

     

    Hope it helps.

    ------------

    If you like this post, give it a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users to find it.

  • Christian Leverenz Profile Picture
    1,214 on 11 Feb 2022 at 09:33:11
    Re: Hide Web Link based on Web Role

    Hi @Anonymous ,

     

    as far as i know you can check the roles of a user in liquid. ( https://docs.microsoft.com/en-us/powerapps/maker/portals/liquid/liquid-objects#user ). So, you could place a javascriptoneliner to hide that menueitem when the user has a specific role.

    Or just go to the headertemplate and apply a condition while rendering, whether this user is in the specific role and just do not render the menueiten.

     

    Nevertheless: you have somehow to give the code knowledge WHICH menuitem is not to be rendered. Either, you do it by name or you add a custom attribute to the weblink (which i usually try to avoid).

     

    Hope it points in a solutiondirection.

    Have fun,

    Christian

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

Announcing our 2025 Season 2 Super Users!

A new season of Super Users has arrived, and we are so grateful for…

Paul Stork – Community Spotlight

We are honored to recognize Paul Stork as our July 2025 Community…

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Pages

#1
Lucas001 Profile Picture

Lucas001 60 Super User 2025 Season 2

#2
Fubar Profile Picture

Fubar 55 Super User 2025 Season 2

#3
surya narayanan Profile Picture

surya narayanan 35

Loading complete