| Back to top |
In the full-featured JavaScript detection file (which I am planning to use unmodified apart from adding a prefix to all global vars in order to avoid conflicts with other scripts), I noticed that variable "brow" does not contain a browser name for Mozilla browsers. What is the reasoning behind this?
For now, in order to have a nice browser string for display to end users, I have simply added the following to my script: if (typeof moz_brow != "undefined") { brow = moz_brow; var moBrowName = moz_brow + " " + moz_brow_nu; } else { var moBrowName = brow + " " + nu; } If I am missing the point, please let me know! |
|||||
|
techAdmin
Back to top
Status: Site Admin Joined: 26 Sep 2003 Posts: 850 Location: East Coast, West Coast? I know it's one of them. |
That's a good idea. I have to admit that I've completely stopped using the javascript browser detection on sites, I only use php browser detection currently, but you've found some nice fixes and improvements which I'll add to the main script since it tightens it up a bit, thanks.
|
|||||
| Back to top |
Do you plan to keep the scripts updated in the future? When I found your site I thought it was a great idea to share the knowledge about browser detection, and obviously it would be great if people were to keep contributing...
I like the client-side detection because it works well even when the page is tested locally and when serving it from Tomcat... |
|||||
|
techAdmin
Back to top
Status: Site Admin Joined: 26 Sep 2003 Posts: 850 Location: East Coast, West Coast? I know it's one of them. |
The client side browser detection doesn't require much updating, except for small fixes like the ones you noted. That's because there is a very small set of browsers out there that will execute javascript, so it doesn't need to change much, just to handle new js supporting browsers like safari etc.
|
|||||
|
All times are GMT - 8 Hours
|
||||||
Contact Us
Hosting: Pair Networks: 0.046
Forum Software © 2001–2006 phpBB
techForum Style © 2003–2006 techpatterns.com
info
Hosting: Pair Networks: 0.046
Forum Software © 2001–2006 phpBB
techForum Style © 2003–2006 techpatterns.com
info