WSHelper variables and records
The WSHelper library provides public variables and records.
WSQueryType
The WSHelper library defines
WSHelper.WSQueryType
as a dynamic
array:PUBLIC TYPE WSQueryType DYNAMIC ARRAY OF RECORD
name STRING,
value STRING
END RECORD
The fields of the record are:- name is the name of the query argument.
- value is the value of the query argument.
WSServerCookiesType
The WSHelper library defines
WSHelper.WSServerCookiesType
as a dynamic
array:PUBLIC TYPE WSServerCookiesType DYNAMIC ARRAY OF RECORD
name STRING, # Cookie name
value STRING, # Cookie value
path STRING, # Cookie path (or null)
domain STRING, # Cookie domain (or null)
expires DATETIME YEAR TO SECOND, # Cookie expiration date (or null)
httpOnly BOOLEAN,
secure BOOLEAN
sameSite STRING # Lax (default), Strict, or None (requires secure)
END RECORD
The fields of the record are:- name is the name of the cookie to be set. This field is mandatory. It will be URL-encoded on the wire.
- value is the value of the cookie to be set. This field is mandatory. It will be URL-encoded on the wire.
- path is the main path the cookie has to be set for. Any path containing that main path will then return the cookie. If no name is set, the cookie will be set by the path the client has provided.
- domain: the domain (hostname) or sub-domain (ex: .strasbourg.4js.com) the cookie will be set on client side. If not set, the domain will be the hostname provided by the client.
- expires: a
DATETIME YEAR TO SECOND
(on local time) from when that cookie will expire, and thus not be sent by the client anymore. IfNULL
, the cookie is called session cookie and will be sent as long as the client keeps the session open. - http_only is set to
TRUE
if the cookie is only for the HTTP layer,FALSE
if cookie can be accessible in JavaScript. - secure: true if cookie must only be sent in HTTPS, false for HTTP and HTTPS.
- sameSite: is the value that defines security from cross-site attacks when
cookies are used. Three values are possibles for sending cookies to other sites: "Strict", "Lax", or
"None". The default is "Lax". If
NULL
, the default "Lax" is used.