Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.


  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • DownloadDownload
  • PrintPrint
Share this Page URL
Help

Part III: Installable Component Reference > Browser Capabilities Component

Chapter 14. Browser Capabilities Component

One of the challenges of constructing a useful web site today is determining what your users' browsers can and cannot interpret in the form of content. Generally, if you know the browser the current user is using, you know its base capabilities. For example, you know that if the user is using Netscape Navigator, then he must have an ActiveX plug-in to use ActiveX controls. However, what if the client is using a less well-known browser? Can you be sure the browser even supports cookies?

In an attempt to help with this problem, Microsoft introduced the Browser Capabilities component. You use the Browser Capabilities component to create a BrowserType object. When you create a BrowserType object, the web server retrieves the HTTP_USER _AGENT header sent by the client. Using this information, the BrowserType object compares the information from this header to entries in a special file (BrowsCap.ini ). If a match for the current client's browser is found, the BrowserType object determines all the properties for the specific browser. Your scripts can then reference the properties of the BrowserType object to determine the capabilities of the user's browser. The following steps summarize this process:


  

You are currently reading a PREVIEW of this book.

                                                                                        

Get instant access to over
$1 million worth of books and videos.

  

Start a Free Trial