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\");
There is not any simple 'mobile=true' flag. You simply have to check by yourself. From here you can find subset of of values to search (list is rather old, so newer mobile browsers should be added).