Understanding properties

 

Properties play a major role in BrowserHawk because they provide the information for which capabilities a browser does and does not support. Furthermore, properties also provide other information specific to the user’s environment, such as the likely native language of the person using the browser, and which operating system they are using.

 

The maindefs.bdf file contains several properties which detailed information about the browsers being used to view your site. In the event there are browser capabilities you want to track that are not included in this file, you can easily add new properties and set them accordingly for each defined browser and folder.

 

Note: Although a "folder" object is never matched as a browser visiting your site, the property information you set for the folder is used as the default values that browsers created under than folder will inherit.

 

Defined properties are easily accessed from your web script after creating the BrowserHawk object. Checking the value of the BrowserHawk object’s properties and writing your scripting logic around the returned value is a fundamental part of using BrowserHawk in your scripts. For example, you may want to check the value of the Frames property and if equal to False, redirect the visiting browser to an alternative version of your site.

 

See Also:

Property data types

Working with properties

The Properties Window Pane

Property differences from browscap.ini