London Dev Meetup Rescheduled! Due to unavoidable reasons, the event has been moved to 21st May. Speakers remain the same—any changes will be communicated. Seats are limited—register here to secure your spot!
AI OnAI Off
London Dev Meetup Rescheduled! Due to unavoidable reasons, the event has been moved to 21st May. Speakers remain the same—any changes will be communicated. Seats are limited—register here to secure your spot!
var pageRouteHelper = EPiServer.ServiceLocation.ServiceLocator.Current.GetInstance<IPageRouteHelper>(); var currentPage = pageRouteHelper.Page;
I found this as an answer to a similar question and its working for me, - however this is my very first Episerver project, and would just like confirmatoin, that this is the "best practice way" to do this?
As far as best practice goes it is to build your blocks so that they don't need to know which page they are on.
Hi Guys,
I have a block on a page in Episerver, (content area) - from within the controller for the block how can I determin the node that represents the page that this block appares?