iPhone fullscreen webapp without AJAX - iphone

I'm building an iPhone webapp (using JQTouch at the moment). It's a fullscreen app, you know, the ones installed on the home screen without the Safari chrome. If you tap a normal link (without AJAX that is) the link opens in Safari, taking you out of the webapp.
Is there a way to build non-AJAX webapps for iPhone?
The problem is AJAX isn't always a feasible solution. I would like to implement OpenID for this particular webapp for example but it means you have to redirect to an OpenID provider which links back to your URL but... without AJAX off course...
PS: I know you can build "real" apps with PhoneGap (and others) and I even built native apps before but, to be honest, I'm tired of paying €70/year for building free apps (it's for a hobby project, nothing professionally).

I think you can open OpenID links in iframe. OAuth, Facebook Connect, etc, all can work in that way.

Related

Facebook deeplink doesn't work in web browser

We're trying to implement deep links in facebook ads. Everything works fine when we open ad link in facebook app: if our app is curretly installed then facebook app launches our app and passes the deep link into it. Also if our app is not installed and we open ad link in facebook app then it redirects to AppStore and we recieve deferred deep link from facebook inside our app.
But when we try to reproduce all these scenarios using facebook browser version, none of the cases are working (neither deep link nor deferred deep link)
Is it possible at all to make deep links work in web environment?
Finally I've asked Facebook support and received the answer:
Deep link is designed to work in apps only. It doesn't work with a
browser. Please don't worry because it's working as expected!
https://developers.facebook.com/support/bugs/535030953629446/?disable_redirect=0

Detecting installed apps on iPhone with javascript or url

I am building a HTML5 based mobile web app for iPhone. I need to check whether user has specific application that I suggest. I heard that each iPhone application has unique URL scheme to detect their app indentity.
Therefore, I've read this article to get an idea.
Is it possible to register a http+domain-based URL Scheme for iPhone apps, like YouTube and Maps?
However, this is not perfect answer to make what I am trying to make.
here is what might happen
User clicks a recommendation app on mobile web browser.
Check with application iTunes URL and URL scheme.
If the user has the installed application, it returns 'installed'
==> In this case, the screen returns back to mobile browser.
If the user does not have the installed application, it returns 'uninstalled'
==> In this case, the screen moves to App Store.
I am running mobile web app with PHP language.
Thank you.
this is not possible I'm afraid. To be honest I'm glad, as there are real privacy concerns if any old web page can detect which apps I have installed.
That's definitely not a good thing!
UPDATE: If you're happy to go native, this library will do what you want.. http://www.cocoacontrols.com/platforms/ios/controls/ihasapp
If you know that a url scheme for the app exists then you can open it via a web link like this, "myapp://". With this there are some round about ways you can effectively check if a certain app exists.
See this related stackoverflow post

Does it violate Apples TOS to use AppMobi and ASP.NET MVC

I'm thinking of using APPMobi to push to the IPhone. APPMobi allows you to code in html and javascript and tap into your phone's functions.
This opens up the obvious desire to code an ASP.NET MVC app that calls these javascript methods.
I wondering if this behavior would violate Apple's TOS because they wouldn't have control of how we update our site.
No it does not. Ignore the person about about "downloading code at runtime" - it doesn't pertain to html/javascript/css.
The issue is if your page does a redirect to your site only. You're best bet is to design the UI in html/javascript and let that live in the app bundle, then use web services to make calls to get data.
Apple will deny your app if it's just you're mobile website embedded.
you can't download code at runtime, except for html/css/javascript.
this means you can have a webview showing pages from your site. of course if it's just a view on your site maybe someone in Apple could argue you should do a webapp instead...
i mean: if they don't allow you to dowload web pages they should ban safari, but if your "app" works perfectly from a browser you risk they refuse it.
hope this help.

OAuth callbacks in iPhone web apps

I'm building a full-screen iPhone optimized web app. It gets launched from the homepage like a native app and behaves like a standalone app via the following directive, but it's just plain HTML/CSS/JavaScript, no PhoneGap involved.
<meta name="apple-mobile web-app-capable" content="yes" />
When trying to authenticate over OAuth, the redirect to Twitter (or any other OAuth provider) takes me out of my full-screen web app and into Mobile Safari. Once the Twitter auth completes, the redirect back to my app does not launch my homepage app, instead just redirects within Mobile Safari. Is it possible to do OAuth inside an iPhone homepage web app? Short of that, can I get the OAuth callback to re-launch my homepage web app?
I've had a similar problem recently, and found that if you set the URL in Javascript with a window.location.href="http://example.com/whatever" then iOS doesn't switch to Safari. I've managed to get PayPal checkout and Facebook login working in standalone web apps without switching to safari using this method! If you're submitting a form, do that via JS too and get the redirect URL from the response then set the location. As for handing back to your app afterwards, it depends on how the external service works.
If that's no good, you could do a pop-up alert('You will be passed to Safari for authentication. Reload this app afterwards.') before they get switched to Safari. Not great, but better than surprising them with automatically switching apps!
I´m assuming that you have a "manifest" meta tag to reference manifest.json file.
I suggest you to do the following workaround. It works perfect on ios safari web app:
https://stackoverflow.com/a/52286655/8390589

Can Facebook's "Single Sign On" be achieved within a mobile web app?

It's my first posting on here (although I've been using this site for reference for quite some time).
I've been trying for several days now to find or dream up a way to use Facebook's "Single Sign On" from within a mobile web app (not a native iOS or Android app) to automatically sign a user into a web app if they are already logged into Facebook from the native Facebook app on their mobile device for example.
My limited knowledge is telling me that it can't be done since the mobile browser and the 'system' (iOS for example) are too separated (I can't, I don't think, have my mobile web app use or access the native Facebook app on a mobile device in any way).
I have found and read the iOS, Android AND Mobile documentation provided by Facebook (https://developers.facebook.com/docs/guides/mobile/) which all seems to make enough sense, but after days of trawling through everything else I could find on the subject there doesn't seem to be a way to use, for example, the Facebook app on an iPhone or Android device to automatically log a user in to my web app if he/she is already logged into Facebook.
I've read lots about doing this from within 3rd party native apps and also other people trying to achieve a similar thing from within Desktop apps but I'm trying and hoping to be able to achieve this from a web app running within a mobile web browser.
I'd be very grateful for any help, opinions or pointers in the right direction since I think this would be an excellent step forward in UI for mobile web apps to have (not just the native apps).
Many thanks in advance...
Probably a bit late to the party but in case anyone else is wondering yes it's possible with Cordova/Phonegap and the Facebook Connect Plugin: https://github.com/davejohnson/phonegap-plugin-facebook-connect/
Using the FB.getLoginStatus() method at startup allows to check if the user is already signed in with the native Facebook App and retrieve its profile. More details in the examples provided in the repo.
I have not yet implemented it myself, but seems possible according to:
http://developers.facebook.com/docs/mobile/web/build/#login