You are not logged in.
Pages: 1
Topic closed
Hey guys,
How can I get HttpServletRequest, HttpServletResponse and Session in a rs script?
Thanks
Offline
Hi Marcos,
you can access these objects (if available) like this:
def requestProvider = GLOBALS.getProvider(HttpServletRequest.class)
HttpServletRequest req = requestProvider.get()
Instead of getProvider() you might need to use getRsServiceProvider() depending on your version.
You can also use GLOBALS.getInstance() (or getRsService() in older versions) to directly retrieve an instance instead of a provider.
Cheers,
Thorsten
Thanks a lot Thorsten.
Offline
Pages: 1
Topic closed