1

I want to forcefully load the Desktop View of any website in Cordova App for iPad. I am trying to loading in both iframe and InappBrowser.

  • By changing User Agent; I tried several methods to change User Agent but no luck. Any idea on this please? If we change user agent will the Apple reject the app while submitting for App Store?

  • I saw the option in Safari in iPad for 'request desktop site'. Can we do it programmatically in Cordova? or any option in iFrame for this?

  • Normally the website is redirecting from the Desktop url to mobile site url. So disable redirection is a solution? If so is there any option for that?

  • Change the iFrame size to pc desktop size and scale to reduce; I tried this but mostly not working.

  • or is there any other solution.

Thanks

Anu
  • 93
  • 2
  • 9
  • Have you tried this method via config.xml? State what you've tried :) http://stackoverflow.com/q/32052221/371637 – Adam Tuliper Feb 17 '16 at 05:11
  • i tried that. but the targeted website is not depends on the user agent i think. – Anu Feb 21 '16 at 06:24
  • are you getting served up different content? Desktop view typically involves identifying yourself as a desktop browser to a destination site – Adam Tuliper Feb 23 '16 at 19:32

1 Answers1

0

It was working fine before version 4.0.0 of cordova-ios (Different from cordova version). To be able to do that again a quick fix can be to remove the ios folder created by the new version and adding the old one:

cordova platform rm ios
cordova platform add ios@3

Hope it helps

user1928596
  • 1,503
  • 16
  • 21