June 18th, 2012, 11:11 PM
How to detect PDF Viewer plug-in from a servlet
I need a servlet code that would return the type of client browser and detect if there is a PDF Viewer plug-in installed on it.
I've tried using HttpServletRequest 's available .getHeader("User-Agent") like the following :
String userAgent = request.getHeader("user-agent");
But it only returns the following browser types and no plug-ins :
"Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; .NET CLR 2.0.50727; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729; .NET CLR 1.1.4322; InfoPath.2)"
Is there any way that I could detect a PDF Viewer plug-in inside a servlet?
Any answer would be greatly appreciated.
Thank you very much!
Tags for this Thread
Click Here to Expand Forum to Full Width
This is a Codeguru.com survey!