0

I am having a requirement where a website ( url is hardcoded )would be getting open in full-screen mode

i.e. No address bar or No menu-bar buttons of SAFARI should be displayed in my application.

I am using following lines of code for the opening url in SAFARI browser.

NSURL *url=[[NSURL alloc]initWithString:@"http//www.google.com"];
[[UIApplication sharedApplication] openURL:url];

what properties shall I set for UIApplication so that I will get the SAFARI browser in full-screen mode in my app?

laxonline
  • 2,657
  • 1
  • 20
  • 37
Sorter
  • 9,704
  • 6
  • 64
  • 74

1 Answers1

1

You can't do this from the Application, it is up to the website to try and enforce this. In order to achieve what you're after, I believe you need to make the website pretend to be a web-app.

Apple have documentation on how to customize Safari for your website, see http://developer.apple.com/library/safari/#documentation/appleapplications/reference/safariwebcontent/configuringwebapplications/configuringwebapplications.html, specifically "Hiding Safari User Interface Components"

WDUK
  • 18,870
  • 3
  • 64
  • 72
  • I don't want to use Web App I want to do this using native application. – Sorter Jan 23 '13 at 11:23
  • If you want to launch Safari outside of your application, you've relinquished control of its presentation. There is nothing you can set in `UIApplication` to perform what you want. You can in theory, have a `UIWebView` within your application pointing to the URL, and that will not come with any navigation controls for you, but it will not open the Safari app, it's still within your application. – WDUK Jan 23 '13 at 11:29
  • I have already tried with UIWeb View but it has got its own problem such as it do not allow popup in its control and also it do not support secure websites having private SSL certificate. – Sorter Jan 23 '13 at 11:34
  • By popups, do you mean popup webpages, or Javascript popups? It will allow the latter, unsure on the former. As for private SSL certs, see http://stackoverflow.com/questions/8858674/allow-unverified-ssl-certificate-in-uiwebview on ways to achieve using your own custom certs. – WDUK Jan 23 '13 at 11:43