Secure > Session management


Set the expiration time of the referral cookie

Set the expiration time enables you to change the tracking behavior of the referral cookie. The referral cookie is used for marketing activities, to track the URL that referred the customer to the WebSphere Commerce site. That is, it tracks the URL that was displayed in the customer's browser immediately before navigating to the WebSphere Commerce site.


Procedure

  1. Open the WebSphere Commerce configuration file.

  2. Search for the <SessionManagement> block.

    For example:

    <SessionManagement>   
    <url-rewriting
          display="false" enabled="false"/>   
    <cookie
          acceptance="false"
          age="-1"
          display="false"
          domain=""
          enabled="true"
          path="/" persistence="wcs"/>    <referrerCookie
          age="-1"/>
      
    <PersistentSession
          cookieExpiry="30"
          delayNewPersistentGuestSession="true"
          display="false" enable="true"/>   
    <PersonalizationId
          display="false" enable="true"/>
    </SessionManagement>
    

  3. Edit the value for the referrerCookie age attribute.

    The attribute is defined in the following form:

    referrerCookie age

    (Integer) The age value is in seconds. If the value specified is invalid, the default value is used. The default value is -1.

    The possible values are:

    • A positive value, indicating that the cookie expires after the specified number of seconds have passed. The value represents the maximum age for the cookie to expire, not the cookie's current age.

      Setting the value to 1209600 indicates that the cookie expires after two weeks, maintaining its previous default behavior in WebSphere Commerce.

    • A negative value, indicating that the cookie is not stored persistently and will be deleted when the Web browser exits.

    • A value of 0, indicating that the cookie will be deleted.

  4. Propagate the changes to the WebSphere Commerce configuration file.


+

Search Tips   |   Advanced Search