Love Fuel?    Donate

FuelPHP Forums

Ask your question about FuelPHP in the appropriate forum, or help others by answering their questions.
iPhone Full Screen not recognized by Agent
  • Hello folks, I'm just working on getting a little jQuery Mobile app going. As per usual, I put in the meta tag
    <meta name="apple-mobile-web-app-capable" content="yes">
    
    so as to be able to make my app a fullscreen web app on iPhone. However, if I access it from the web app bookmark on my homescreen, instead of being presented with my mobile interface (if the device is mobile it gets the mobile version, otherwise the desktop version, etc) I get the desktop version. So I did a var_dump() on Agent::properties(). In safari on the iPhone it is recognized perfectly. As a web app, it is only recognized as "Default browser" on unknown platform. Anybody have any ideas? :\ Thanks! Edit For now my fix is checking the $_SERVER for iPhone
  • How is your agent class configured? This suggests the browscap file isn't fetched or installed. If you surf to http://browsers.garykeith.com/your-browser, what does that say? If that gives you the correct information, the browscap file (which is downloaded from this site) is ok.
  • Harro Verton wrote on Sunday 1st of April 2012:
    How is your agent class configured? This suggests the browscap file isn't fetched or installed.

    Thing is, it correctly identifies browser and platform when accessed directly from Safari rather than as a web app.
  • I'm not familiar with the platform, so I don't know what you mean by "as a web app". But I assume that it doesn't use the normal Safari as client, so the user agent string is not recognized by the Agent class. See if you can log the information on the server, and send it to Gary Keith who maintains the browscap file, so it can be included in the file.
  • Harro Verton wrote on Monday 2nd of April 2012:
    I'm not familiar with the platform, so I don't know what you mean by "as a web app". But I assume that it doesn't use the normal Safari as client, so the user agent string is not recognized by the Agent class. See if you can log the information on the server, and send it to Gary Keith who maintains the browscap file, so it can be included in the file.
    On iOS, when browsing in Safari you can add websites to your home screen as their own application. In doing so, it makes the site look much more like a native application by removing the address bar and the 'actions' bar at the bottom (back, forward, send to, bookmarks, tabs, etc). It also gives the web app that much more space (so if it is checking based on the window height and width it'd be different). But it should still be a wrapper for Safari and the User Agent very similar if not the same. I will see what other information I can collect on that issue and forward it on to Mr. Keith. Thanks.
  • I have same problem.
    Firefox 26 on Windows 7 with this code echo Agent::browser();
    It was return Default Browser.

    I use default configuration.
  • Same answer I'm afraid.

    I ran some tests, it detects firefox up to version 24. If I change the version to 25 or up, it not longer detects the browser. So the browscap files are in need of updating.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

In this Discussion