More in this section
Forums / Developing with Sitefinity / Different pages for registered users

Different pages for registered users

The forums are in read-only mode. In case that you want to directly contact the Progress Sitefinity team use the support center. In our Google Plus group you can find more than one thousand Sitefinity developers discussing different topics. For the Stack Overflow threads don’t forget to use the “Sitefinity” tag.
2 posts, 0 answered
  1. Muhammad Saqib
    Muhammad Saqib avatar
    95 posts
    09 Sep 2009
    12 Nov 2010
    Link to this post

    I need urgent help on the following. I created a page named Download.html and its published, Now what i want is to Display slightly different text for anonymous user and different for registered users on the same page. What best way i can do to achieve this in sitefinity.
    Secondly, is there any way to customize the loginview control in sitefinity (Under Login tab in the desing view admin panel)
  2. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    12 Sep 2017
    12 Nov 2010
    Link to this post
    Hi Muhammad ,

    1. You can get the current user and its roles by using UserManager class
    2. If this is a content item you can create an additional metakey where you can set which role/user can see the content, so that you can easily retrieve the correct content by using GetMetaData method of IContent object.

    You might find this post useful hiding controls beased on roles

    The LoginView control - this is the standard ASP.NET control. You can expose all public properties of the control in a custom control designer

    Sincerely yours,
    Ivan Dimitrov
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
2 posts, 0 answered