开发者

Request variable in dotcms

Please find my requirement that needs to be done in dotcms-

1) I need to create a Map object for each request开发者_如何学C. 2) Across different widgets or containers i should be able to add data or get data from the Map object.

Can you please provide me a solution or idea to fulfill the requirement.

Thanks in advance


You can use the standard HTTPServletRequest methods, even from velocity:

$request.setAttribute("foo", "bar")

$request.getAttribute("foo") would print "bar"

$request.getParameter("foo") would get a GET or POST parameter "foo" and

#set($map = ${request.getParameterMap()}) would get the whole map.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜