OpenWGA 7.9 - TMLScript reference

TMLPortlet "portlet"
Method :

setSessionVar(name, value [, allowSerialisation])

On object TMLPortlet "portlet"
Usage Sets a WebTML portlet session variable
Description Portlet session variables are WebTML session variables that are only visible inside the portlet they were set for. Use them to avoid name collisions with variables of other portlets and therefor increase portlet modularity.

Besides this portlet variables behave the same way as normal WebTML session variables. They are retrievable via this.item() (NOT portlet.item() which is exclusive for portlet items) and can be used as regular WebTML variables by all functionalities that use them, either in TMLScript or WebTML. Additionally their scope spans the whole browser session. They become available again when their portlet is re-rendered.
Parameters name (String):
Name of the variable

value (Object):
Value of the variable

allowSerialisation (Boolean, optional):
Controls if this variable should be serialized to other cluster nodes in a server cluster. This is only possible if the value type is serializable. Defaults to true.
Allowed in script types
  • WebTML pages and normal WebTML actions