<?php

require 'browserhawk.php';

// This sample is provided under the terms of the BrowserHawk End User License
// Agreement.  Copyright (c) 2003-2006 cyScape, Inc.  All rights reserved.

// This sample demonstrates how to use the BrowserHawk4J library from PHP to
// detect basic properties.  "Basic" properties are properties that are the
// same for all browsers of the same type, version and platform.  For example,
// the Browser, Platform, Version, FileUpload, and XML properties will always
// be the same for a specific browser such as IE 7.0 on Windows XP.  These are
// properties that the end user does not affect by changing their preferences
// or settings on their computer.

// Conversely, "extended" properties are properties which can vary depending
// on how a user has configured their browser or system.  Broadband,
// CookiesEnabled, Plugin_Flash, WidthAvail, and HeightAvail are examples of
// extended properties.  Extended properties are a bit more advanced so we do
// not cover them here in this basic sample.  Instead see the popular.php for
// more information on detecting extended properties.

// For more information see:
// http://cyscape.com/docs/showhelp.asp?topic=basic_vs_extended_browser_properties

?>

<html><title>BrowserHawk Sample - Basic Browser Detection (PHP)</title></head>
<body><font face="arial">
<blockquote>

This sample demonstrates how to detect basic properties using BrowserHawk.
"Basic" properties are properties that are the same for all browsers of the
same type, version and platform.  For example, the Browser, Platform, Version,
FileUpload, and XML properties will always be the same for a specific browser
such as IE 7.0 on Windows XP.  These are properties that the end user does not
affect by changing their preferences or settings on their computer.

<P>

Conversely, "extended" properties are properties which can vary depending on
how a user has configured their browser or system.  Broadband, CookiesEnabled,
Plugin_Flash, WidthAvail, and HeightAvail are examples of extended properties.
Extended properties are a bit more advanced so we do not cover them here in
this basic sample.  Instead popular.php demonstrates how to detect extended
properties.  <P>

See the <a href="http://cyscape.com/docs/showhelp.asp?topic=basic_vs_extended_browser_properties" target="_new">Basic Vs. Extended Properties topic</a>
in the documentation for more details on how basic and extended properties
differ.
<P>
<HR>
<P>

Your browser is: <?php echo $info->getBrowser() ?> <?php echo $info->getFullversion() ?><P>


Your platform is: <?php echo $info->getPlatform() ?><P>
Browser major version: <?php echo $info->getMajorver() ?><P>
Browser minor version: <?php echo $info->getMinorver() ?><P>
Container* browser: <?php echo $info->getContainerBrowser() ?><P>
Container version: <?php echo $info->getContainerVersion() ?><P>
Container full version: <?php echo $info->getContainerFullversion() ?><P>
Supports AJAX? <?php boolprint($info->getXMLHttpRequest()) ?><P>
Supports ActiveX controls? <?php boolprint($info->getActiveXControls()) ?><P>
Browser data file version: <?php echo $info->getBDDVersion() ?>, dated: <?php echo $info->getBDDDate() ?><P>
BrowserHawk version in use: <?php echo $BrowserHawk->getVersion() ?><P>

<p>
*Note: The "Container" properties are used to detect cases where an IE
rendering engine is running inside of another browser.  For instance Netscape
8 and later and AOL Explorer can emulate IE.  In these cases the
ContainerBrowser, ContainerVersion, and ContainerFullversion will contain
details about the browser that the IE engine is running inside of.  For
instance with Netscape 8.0.0.3 running in IE emulation mode, BrowserHawk will
return "Netscape", "8.0", and "8.0.0.3" for these properties respectively. 
<p>
<HR>

<P>
<b><a href="basics.php">Retry this test</a></b><P>
<b><a href="index.html">Return to list of other PHP samples</a></b><P>
<b><a href="http://www.cyscape.com/order/">BrowserHawk Pricing and Ordering</a></b><P>
<b><a href="http://www.cyscape.com/">cyScape home page</a></b><P>
</font></blockquote>
</body>
</html>
