PDA

View Full Version : Browser detection



erik
07-28-2001, 10:55 AM
Hi,

I have seen the procedures for detecting Acrobat, I was wondering if a similar procedure existed for detecting the browser. My concern here would be to distinguish between the two principle browsers that we would like to offer for installation, Netscape and Explorer. We would like to check what (if any) browser is already installed, and offer the user the option of upgrading based on existing browser version (I assume this would be defined by the .htm extension association).
If no browser is installed, to give the user a choice of the two options.

Thanks for any insght you can provide in the approach I should take,

Erik

Adam
07-30-2001, 09:25 AM
You can search the registry for the .html extension.

Action: Read from Registry

Name:%RegVar%
Default: FALSE
Main Key: HKEY_CLASSES_ROOT
Sub Key: .html
Value Name: .html
True if Exists: Checked

This will give you a pretty good idea if the user has an Internet browser installed.

The following two registry keys may help to determine if the user has one or both of these browsers installed.

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Internet Explorer\Version

HKEY_LOCAL_MACHINE\SOFTWARE\Netscape\Netscape Navigator\CurrentVersion

You could read from registry to determine the existence of these keys then show a page/button to install the appropriate browser.

I hope that this will get you on your way to solving your problem.



------------------
Adam Kapilik
Indigo Rose Corporation