Get accessibility assigned to page
HI Team,
Sitefinity version : 4.1 SP2
We are developing one request base access system where if some user doesn't have access on particular page then we are redirecting to NoAccess page. There user will be provided with the message and button to send request to admin for assign him that role require for page.
To get the role assigned to the page we are trying to get the page node GetPAgeNodes() by passing the page url also tried using pate title but every time it is returning null. Following is code.
PageNode pga = pageManager.GetPageNodes().Where(pD => pD.Title == currentAccessedPage).FirstOrDefault();
We have gone through the existing threads of Sitefinity forum for getting page details.Most of the forum post has same solution.We also tried with fluen API but no luck.
Guide us to get page details.
Regards,
Jesse
Hi Jesse,
Try this:
PageNode node = App.WorkWith().Pages().Where(p => p.Title == currentAccessedPage.Title
).Get().FirstOrDefault();
Telerik.Sitefinity.Pages.Model
and
Telerik.Sitefinity
namespaces.
Hope that helps.
Greetings,