Question
I have a HTML5/JavaScript app. I would like to submit it to the apple store.
Is there anyway I can somehow embed this in Safari/Webkit, and have apple accept it as an app?
Context
This project started out as a web app, but I've found I like javascript/SVG far far more than Objective-C. And thus, I'd prefer to keep my development in JavaScript, but yet somehow be able to submit to the apple Mac store.
Clarifications:
I'm aiming for the Mac store, not the iOS stores.
Thanks!
This is what phonegap is all about. Take a look at http://www.phonegap.com . It is an open source project for writing cross plattform mobile apps in html5 which can be run on many different plattforms.
There is a port out there called phonegap-mac which is for the apple desktop. (see: https://github.com/shazron/phonegap-mac)
I have used it several times to host html5 apps as an "app" on mac desktops.
I am not aware right now if there are any restrictions for the app store for desktop apps not allowing phonegap, but in general there should not be.
Related
I would like to make an app for Android and iOS:
Consider a feature-similar app like Uber using the map and its location features, widgets on the map, login screen, camera and WIFI information (what wifi hotspots are available and if it’s private or free, etc). The user also needs to use either paypal or credit card.
What would be better: using HTML5, CSS and javascript or developing a separate app for Android and iOS? Or maybe developing in C++ and creating two UIs for Android and iOS?
Are frameworks (like phonegap) best for high-level apps like games that don't need too much access to native features?
The best thing to do is develop a separate app for Android and iOS.
Making them separate you can maintain the high performance for both operating systems.
And obviously Android and ios have guidelines regarding the graphics very different. So if your goal is to get high performance from your app, you should definitely make two apps for the two operating systems. Instead, if your goal is to have an app to be published in a short time you can make a hybrid application.
I think this 'true image' will clarify your ideas
Speaking from personal experience (working in parallel on iOS and Android right now with some mapping apps):
- Android's ties to GooglePlay for all mapping services are a big headache
- Implementation of GoogleMaps SDK on iOS is NOT the same as on Android
If you want a very similar look and feel for both platforms; go with web-based.
I'm trying to develop a small Windows 8 App as a test for a larger project that I'll be working on.
I'm using VS 2012, HTML, CSS, and Javascript. I've been able to create, build and deploy the app with out a problem, however I notice that if I put my tablet into airplane mode (i.e. take it offline) and then try to open the app, I just get a black screen.
Is there a "best practice" for handling offline scenarios?
I am familiar with using manifest for mobile web apps, but this doesn't seem matter here.
Use applicationData. http://msdn.microsoft.com/en-us/library/windows/apps/hh465118.aspxSource: http://social.msdn.microsoft.com/Forums/en-US/winappswithcsharp/thread/a5f0477d-c665-477e-b118-77446b7029ce
Need to use NetworkStatusChange event and take require action. this quickstart at msdn also documents the best practices.
You can try out some application from Microsoft like Store, news, music to give idea for offline behavior of your app.
I am interested in web standards (js/HTML/CSS). I would like to create applications from them, for phones and tablets. And sell these applications on mobile stores and web stores (for appstores and google play).
Is it possible ? What would be the best way to do it ?
Yes, there is a PhoneGap platform that can be used for building mobile apps for iOS, Android, Symbian, Windows Phone.Apps developed with it are accepted in all the stores. It is quite popular, robust and has nice features.
As mentioned in one of the other answers, yes PhoneGap will do the trick if you decide to write your app in HTML/CSS/JavaScript. Now, if you want to have a pleasant user experience on both smartphone and tablet operating systems, I would also recommend looking into Twitter Bootstrap.
This CSS framework has built-in responsive web-design styles that will allow you to scale things down in a user-friendly manner from tablet to smartphone, as well as show/hide different parts of your HTML depending on whether your users are viewing the page on a tablet or smart phone.
Specifically, you can do things like the following:
<div class="visible-tablet">
This will only be visible on tablets.
</div>
<div class="visible-phone">
This will only be visible on smart-phones.
</div>
For a full listing of the responsive design support in Twitter Bootstrap, check out their section on responsive design.
You may also want to check out the Google Chrome Web Developer plugin to assist you in creating a responsive web experience. This plugin lets you (among other things) view how your page will look on multiple device resolutions and is an invaluable tool for debugging resolution-specific issues.
You can look at Zurb Foundation, which is a very active open source project for building responsive web apps for mobile devices. Some overall description of the features here.
You can create Windows 8 Apps using Javascript and HTML 5 (apart from using Native languages). Windows 8 runs on Surface tablets and PC's.
Create your first Windows Store app using JavaScript (Windows)
There is a free ebook as well: free-ebook-programming-windows-8-apps-with-html-css-and-javascript
There are lots of options around - PhoneGap seems to be the most popular and, since it's now part of Adobe, it will probably continue to be popular.
However, there is a more important issue to be considered here: iOS users expect an iOS app experience, Android users an Android one... You get the idea. Make sure it's the best choice for your customers.
See this story about HTML5 at Facebook.
Also, and I know I might open a can of worms here, the performance will always be inferior to that of a native application.
You can also try MoSync:
"Build native mobile apps for all the major platforms using our leading open-source, cross-platform development environment. Now with support for In-App Purchases, NativeUI and Windows Phone 7." ]
There's Titanium from Appcelerator where according to their site you can build native apps using Javascript.
Just a late update: Facebook has open-sourced react-native since use asked your question and unlike PhoneGap (now called cordova) React-Native does not build hybrid app but builds true Native mobile application with the same power you would get when using Java for android or ObjectiveC for IOS. You can find out more here
No point in doing Microsoft/Windows Mobile anymore since it's now dead, but the easiest way to create Android apps based on HTML is to use DroidScript which can be found on Google Play (it did not exists at the time of this question).
You can also build native (non-html) apps with pure JavaScript using the same tool and it's far easier to use for novices than PhoneGap/Cordova.
At first glimpse Cordova and PhoneGap exist primarily for the use to develop apps to be used on a mobile device. Well, I am not interessted in the developement of native mobile apps.
There exists a webapplication (a cms) of our own and the question is now if a mobile toolkit like Cordova or PhoneGap is able to be of any help to develop parts of our cms functionalities with it in order to be able to support more plattforms.
Does it make sense to use Cordova or PhoneGap for the developement of a pure browser-based web application?
Phonegap (or Cordova as its now called) works by wrapping your webpages in a Webview and giving you access (in JavaScript) to some of the native device functions, such as the Camera, Accelerometer, Contacts etc.
As for whether it will help you depends on if want to make use of any of the native device functions, for example if you think incorporating the Camera (current HTML support for camera is quite spotty) into your web app is of use then you probably should consider it.
Another consideration is how your users will access the applications, with Phonegap it gets packages into a native app and they can just launch it from their home-screen (or however they launch apps on their mobile device), while with a Web App it depends on the device, on iOS you can pin it to your home screen and add some meta tags to make it appear more native like (for example hide the address bar) while on Android as far as I know you can't do that.
Finally consider that with Phonegap it might be more of a pain to debug your application since your HTML/Js is wrapped in a Webview, but as far as I've seen there is no easy way to debug it there.
One other thing I seem to recall reading somewhere that on iOS Apple doesn't give your native applications' Webviews access to the same amount of memory as if it were in safari so the exact sane web application when packaged into a Phonegap application might actually be slower.
To sum up, the benefits of wrapping your application in a Phonegap wrapper are access to native device functions and how your users access your app, if those aren't important (or the cons outweigh the benefits) than it probably isn't worth your while to go that route.
Cordova/Phonegap extend javascript with functionality provided by mobile operating systems. Therefore apps developed with these frameworks must be compiled to the target platform and only embed the HTML etc. in an embedded browser. The extensions need java, objective-c etc. code to run so I don't think that you are able to benefit from this code.
You are forced to write your own mobile device compliant HTML code when using Cordova/Phonegap. There are no neat mobile device ready user interface controls provided by the framework but only access to device specific hardware or software apis like notification etc. is given.
Cordova is just the latest name of PhoneGap. I would not go for that if you just want to build a mobile website. First of all publishing such an app on several online stores (iTunes, Play) is a pain.
does anyone know how to create a javascript interface in iOS that can be called from javascript? My aim is to save data from a website in a native fashion and not using html5 local storage.
If I understand correctly, what you need is a mobile webapp packaging solution.
The most popular here is, perhaps, PhoneGap, it supports many platforms including iOS. The product is free and open source. You will still need to use Apple's iOS platform SDK and have a developer account. As for storage mechanism, I believe PhoneGap has a solution for it (allowing the storage to be persistent, not cleared out like browsers' localStorage).
If you want to simplify your deployment process, you may want to check out appMobi, they build on top of PhoneGap, providing their own development kit and cloud deployment services.
Also refer to this thread that discusses different kits:
Comparison between Corona, Phonegap, Titanium
UPD. Have you tried the PhoneGap SQLite plugin for storage?