File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Servlets and the fly likes JSP API Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Servlets
Bookmark "JSP API" Watch "JSP API" New topic



Joined: Aug 17, 2001
Posts: 8
I know JSP is mainly java, but is there a seperate API?
I am looking for a function that can detect a user's Browser Type.
Jeff Sunder
Ranch Hand

Joined: Jun 26, 2001
Posts: 47
You need to check the http headers to determine the browser type. Here is a little script that works for me
//determine browser type
if (request.getHeader("USER-AGENT").indexOf("MSIE") >= 0) {
//Your code here
//Your code here
I agree. Here's the link:
subject: JSP API
jQuery in Action, 3rd edition