Skip to main content


class %CSP.UserAgent extends %Library.RegisteredObject

Determine browser parameters from HTTP_USER_AGENT CGI variable.

Property Inventory

Method Inventory


property Browser as %String;
Browser name
Property methods: BrowserDisplayToLogical(), BrowserGet(), BrowserIsValid(), BrowserLogicalToDisplay(), BrowserLogicalToOdbc(), BrowserNormalize(), BrowserSet()
property Platform as %String;
Browser platform
Property methods: PlatformDisplayToLogical(), PlatformGet(), PlatformIsValid(), PlatformLogicalToDisplay(), PlatformLogicalToOdbc(), PlatformNormalize(), PlatformSet()
property SupportsXMLHttpRequest as %Boolean;
Supports XMLHttpRequest.
Property methods: SupportsXMLHttpRequestDisplayToLogical(), SupportsXMLHttpRequestGet(), SupportsXMLHttpRequestIsValid(), SupportsXMLHttpRequestLogicalToDisplay(), SupportsXMLHttpRequestNormalize(), SupportsXMLHttpRequestSet()
property UserAgent as %String;
User agent for this class.
Property methods: UserAgentDisplayToLogical(), UserAgentGet(), UserAgentIsValid(), UserAgentLogicalToDisplay(), UserAgentLogicalToOdbc(), UserAgentNormalize()
property Version as %String;
Browser version
Property methods: VersionDisplayToLogical(), VersionGet(), VersionIsValid(), VersionLogicalToDisplay(), VersionLogicalToOdbc(), VersionNormalize(), VersionSet()


method %OnNew(userAgent As %String) as %Status
Initialize with HTTP_USER_AGENT.
classmethod XMLHttpRequest(userAgent As %String, ByRef browser As %String, ByRef platform As %String, ByRef version As %String) as %Boolean
XMLHttpRequest returns true if XMLHttpRequest object is supported by the browser indicated by the userAgent. Current implementation parses User Agents beginning with:

Inherited Members

Inherited Methods

FeedbackOpens in a new tab
Opera/ Browser type is Opera. The version must be greater than or equal to 7.60.
Mozilla/5.0 ( If the User Agent contains "Safari/", the browser type is Safari. The version number must be greater 119.0.

Otherwise the platform type must be one of Windows, Macintosh, or X11 and the User Agent must contain "Gecko/".

Otherwise User Agent must contain "rv:". The browser type is Mozilla and the version must be greater than 1.3. Camino version 5-- plus browsers listed in exclude-list are not supported.