Javascript: User-agent detect GoogleTV or Boxee


/ Published in: JavaScript
Save to your folder(s)

Simple way to detect GoogleTV or Boxee browsers using Javascript.


Copy this code and paste it in your HTML
  1. //Get the user agent
  2. var userAgent = req.headers["user-agent"];
  3.  
  4. if( userAgent.match(/(Large Screen|GoogleTV|Boxee)/i) ){
  5. //Do something
  6. }

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.