+1-888-365-2779
Try Now
More in this section

Forums / Developing with Sitefinity / Different pages for registered users

Different pages for registered users

2 posts, 0 answered
  1. Muhammad Saqib
    Muhammad Saqib avatar
    95 posts
    Registered:
    09 Sep 2009
    12 Nov 2010
    Link to this post
    Hi,

    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
    Registered:
    25 Nov 2016
    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