menu

SiteGenesis / Server-side JS / Module: request/OnSession

The onSession hook is called for every new session in a site. This hook can be used for initializations, like to prepare promotions or pricebooks based on source codes or affiliate information in the initial URL. For performance reasons the hook function should be kept short.

Source:

Methods

(static) onSession()

The onSession hook function.

Source:

(inner) getDeviceType() → {String}

Gets the device type of the current user.

Source:
Returns:

the device type (desktop, mobile or tablet)

Type
String

X Privacy Update: We use cookies to make interactions with our websites and services easy and meaningful, to better understand how they are used. By continuing to use this site you are giving us your consent to do this. Privacy Policy.