[Elements] are optional
Defined in
0.1/lib.js
Class SAPO.Browser
class
SAPO.Browser
Inclusion link: http://js.sapo.pt/SAPO/0.1/
Sample: http://js.sapo.pt/SAPO/sample/
Variable Summary
boolean
GECKO
True if the browser is Gecko based
boolean
IE
True if the browser is Internet Explorer
boolean
KONQUEROR
True if the browser is Konqueror
boolean
OPERA
True if the browser is Opera
boolean
SAFARI
True if the browser is Safari
string
model
The specific browser model
string
userAgent
The user agent string
string
version
The browser version
Function Summary
Detects the browser and stores the found properties
init()
initialization function for the Browser object
Loads a list of given modules and executes a callback when the modules are ready
Stores window dimensions
Stores the referrer
Variable Details
variable boolean GECKO
True if the browser is Gecko based
variable boolean IE
True if the browser is Internet Explorer
variable boolean KONQUEROR
True if the browser is Konqueror
variable boolean OPERA
True if the browser is Opera
variable boolean SAFARI
True if the browser is Safari
variable string model
The specific browser model
variable string userAgent
The user agent string
variable string version
The browser version
Function Details
function detectBrowser
detectBrowser()
Detects the browser and stores the found properties
function init
init()
initialization function for the Browser object
function require
require(Array|String
reqArray, Function
callBack, Boolean
async)
Loads a list of given modules and executes a callback when the modules are ready
Parameters:
reqArray
- Array of modules (url's, namespaces) to be loaded. If only one module is being loaded, a string can be used
callBack
- callback to be executed after the modules are loaded
async
- If true, executes the callback immediately, not waiting for the modules to be loaded function setDimensions
setDimensions()
Stores window dimensions
function setReferrer
setReferrer()
Stores the referrer