Dec
27
2008

Flash sniffer bug solved

Ever since Flash Player 10 arrived on the scene, Flash websites here and there have begun having a problem: They’ll insist that you need a newer version of Flash Player, in spite of the fact that you’ve got version 10 happily installed. If you’re running Internet Explorer, you won’t have any problem, but if you’re running Firefox, Safari, Netscape, or Google’s new Chrome browser, then there’s trouble.

The problem lies in a small javascript file: brwsniff.js, a handy dandy browser sniffer that checks for the installed Flash Player version number. The bit of code written for non-IE browsers wasn’t expecting a player with a version number of more than one digit; so, seeing only the one’s place digit, if you’ve got Flash Player 10 installed, the script comes up with a version number of ZERO! :arg:

Unfortunately, the author of this otherwise delightful script has not updated the file since before Flash Player 10 was released. Having made the minor repair necessary, I’m making my updated version available for download HERE.

Please note: If for some reason you needed this script to detect the browser software in use, I’m afraid you’re still out of luck. The script seems to see everything as either IE or Firefox.

[UPDATE]
Got a message from Pau Garcia i Quiles, author of jsbrwsniff.  He’ll publish a bugfix soon—until he does, download the version posted here.  I’ll announce when an official bug fix becomes available.  New features he’s planning to add in the coming months:

  • Encapsulation to avoid namespace clashing
  • Java version detection
  • Adobe PDF detection


No Comments »

RSS feed for comments on this post. TrackBack URL


Leave a comment!

NOTE: All comments are moderated, so may take a day or two to appear.

Powered by WordPress | Theme based on Aeros by theBuckMaker | Admin