Visitor API

The Visitor API allows you to customize the visitor side behavior of Cobrowse. For additional information on customization, see Create a Custom Cobrowse Visitor User Interface

Parameters

GLANCE_COBROWSE

You can control Cobrowse parameters by setting properties on the JavaScript variable: window.GLANCE_COBROWSE.

String Properties

The following string properties can be set on GLANCE_COBROWSE. These properties would typically be set if the visitor is logged in and the information is known at the time the page is rendered.

String Description
visitorid
If specified, a visitorid is used as the Session Code when a Cobrowse session starts instead of a random key. A visitorid is often a user ID or some other string that uniquely identifies the website visitor. It may contain alphanumeric characters, (-) and (.). If name, email, and phone number are provided, the visitorid is stored with the session record in the Glance database.
name
Visitor's name.
email
Visitor's email address.
phone
Visitor's phone number.

Example:

var GLANCE_COBROWSE = {
  visitorid: "59204gh-42",
  name: "Joe Smith",
  email: "jsmith@glance.net",
  phone: "314-555-1212"
};

If this variable is defined at the time a session starts, these visitor parameters are used for the session regardless of how the session was started.

GLANCE.Cobrowse.Visitor

The GLANCE.Cobrowse.Visitor object is defined in any web page that includes the Glance Cobrowse script tag.

A sample code which implements a Cobrowse user interface using GLANCE.Cobrowse.Visitor can be found here: http://www.glance.net/cobrowse/js/GlanceCobrowseCustomUI.js.

Properties and Methods

The following properties and methods are available on Glance.Cobrowse.Visitor. Methods marked with (*) can only be called when there is a session running.

By continuing to use the site, you agree to the use of cookies. Learn More