How to check if a web page has been opened by a mobile browser or a computer browser. I tried this :
name = request.getHeader(\"User-Agent\");
You could also look at the size of the screen (smaller size would possibly mean a mobile device), which should be accessible through javascript.