- Description:
- Set of utils for working with web/http in SFCC.
- Source:
Set of utils for working with web/http in SFCC.
Methods
(inner) deleteCookie(name) → {dw.web.Cookie}
- Description:
- Deletes a cookie with the specified name.
- Source:
Parameters:
Name | Type | Description |
---|---|---|
name |
string | The name of the cookie to delete. |
Returns:
The deleted cookie.
- Type
- dw.web.Cookie
(inner) getCookie(cookieName) → {dw.web.Cookie|null}
- Description:
- Retrieves a cookie by its name from the current request.
- Source:
Parameters:
Name | Type | Description |
---|---|---|
cookieName |
string | The name of the cookie to retrieve. |
Returns:
The retrieved cookie or null if not found.
- Type
- dw.web.Cookie | null
(inner) setCookie(name, value, optionsopt) → {dw.web.Cookie}
- Description:
- Sets a new cookie with the specified name, value, and options.
- Source:
Parameters:
Name | Type | Attributes | Description | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
name |
string | The name of the cookie. | |||||||||||||
value |
string | The value to be stored in the cookie. | |||||||||||||
options |
Object |
<optional> |
Additional options for the cookie.
Properties
|
Returns:
The created cookie.
- Type
- dw.web.Cookie