ios - screen orientation issues in phonegap -


i have been using phonegap build. have encountered need run app in portrait mode phones , in landscape mode on tablets (same app - different orientations),from config files see there no such distinction available. pg has ability this?is available in pgb. there soluction this? using below code fixed issues

 var devicetype = (navigator.useragent.match(/ipad/i))  == "ipad" ? "ipad" : (navigator.useragent.match(/iphone/i))  == "iphone" ? "iphone" : (navigator.useragent.match(/android/i)) == "android" ? "android" : (navigator.useragent.match(/blackberry/i)) == "blackberry" ? "blackberry" : "null";     if(devicetype=='ipad')     {     screen.lockorientation('landscape');     }     if(devicetype=='iphone')     {     screen.lockorientation('portrait');     } 


Comments

Popular posts from this blog

c++ - Difference between pre and post decrement in recursive function argument -

php - Nothing but 'run(); ' when browsing to my local project, how do I fix this? -

php - How can I echo out this array? -