We need the instance of PageContext ( javax.servlet.jsp.PageContext ) inside a sightly class which extending WCMUsePojo class.
or through the slinghttpservletrequest/slinghttpservletresponce.
Solved! Go to Solution.
Are you trying something like this, what is the exacyt use case? See this: http://books.gigatux.nl/mirror/javaserverpages24hours/0672325977_ch08lev1sec3.html It explains all and has good sample.
MyGridContainerHelper gridContainer = new MyGridContainerHelper();SimpleBindings bindings = new SimpleBindings()bindings.put("resource", page.getContentResource().getChild("gridpar/my_gridwrapper"))gridContainer.init(bindings)
Views
Replies
Total Likes
That is only available in the JSP-context. Why do you need it?
Views
Replies
Total Likes
As Feike points out - you need to do this in JSP
Views
Replies
Total Likes
Are you trying something like this, what is the exacyt use case? See this: http://books.gigatux.nl/mirror/javaserverpages24hours/0672325977_ch08lev1sec3.html It explains all and has good sample.
MyGridContainerHelper gridContainer = new MyGridContainerHelper();SimpleBindings bindings = new SimpleBindings()bindings.put("resource", page.getContentResource().getChild("gridpar/my_gridwrapper"))gridContainer.init(bindings)
Views
Replies
Total Likes
Not sure why would you need pageContext,
but , I feel you are trying to get instance of some object. do look at https://docs.adobe.com/docs/en/htl/docs/global-objects.html which list default available global objects in sightly
Views
Likes
Replies
Views
Likes
Replies
Views
Likes
Replies