Phonegap WEB-APP without xCode - iphone

I'm building a simple web app for iOS that will not be published to the AppStore.
For infrastructure limits (and my boss!) , I can't use xCode anyway to build the app in a native way.
The only NATIVE functionality required by the web app should be a simple "Add to contacts".
I've tried to implement it with phonegap , but it works only compiled under xCode.
Is there any way to "add to contacts" without building an app (using only a web-app )?
Thanks in advance
Andrea

I don't think there's a way for you to add a contact directly, using only a web app.
PhoneGap was made for this sort of thing, allowing you to access a device's features (like Contacts, Camera, GPS, etc). But if your company's project specifications don't allow for an app... I don't know that there's a way to do this directly, via the web.
If you're building a web app... while you may be targeting iPhones, you're still making it available to anyone with a browser. I'm not 100% on this, but having some way for a web page to directly manipulate a (Mac) user's contacts seems like a security issue.
As a test, I tried placing a vCard on a page, and accessing it via my iPhone. Changing the extension from .vcf to .vcard didn't yield anything (and for some weird reason it prompted me to open the file via Dropbox).
What did work was emailing myself the vcard as an attachment. I was able to view the attachment, which then gave me the option to add the info as a new contact.

Related

Phonegap for iphone development on Windows questino re native api

I've spent the day googling all the leads on developing iphone apps on Windows and apart from buying a mac the most suitable route seems to be Phonegap. I cannot find out whether Phonegap gives access to all the native functionality. For example I want to access and manipulate the address book contents. I also want to be able to send text messages programatically and intercept and examine incoming text messages. It would be helpful if someone could confirm whether this can be done with Phonegap.
My understanding is that Phonegap is based on webapps but I am assuming that an app developed with it can run offline for operations that dont require internet access.
Even using Phonegap you will still need access to a mac to actually build your iOS application. This is a restriction that Apple has in place, and to my knowledge there is no way around it.
Phonegap uses a UIWebView to display your application built using HTML, CSS, Javascript etc, but this does not mean that an Internet connection is required for the app to run (so offline apps are definitely possible).
With regards to Phonegap's functionality, details of the Phonegap API can be found on their website. Specific to your needs, I believe phonegap provides access to the device's address book through the contacts API:
http://docs.phonegap.com/en/2.3.0/cordova_contacts_contacts.md.html#Contacts
I don't think Phonegap provides the ability to send SMS messages itself, but many people have developed extensions to add extra functionality to their applications through plugins. The majority of Phonegap iOS plugins can found at the following GitHub repo. The plugin I think you require is the SMSComposer:
https://github.com/phonegap/phonegap-plugins/tree/master/iOS/SMSComposer

iPhone: Access Camera and Album from Web app

I want to develop a web app using html5, js. One of the feature is to launch device Camera and record video, take a picture and access photo album. Is it possible to access via web app if i develop? I saw in the forums that, it is saying not possible in some places and it is possible in some places. I would like to know, is it really possible to access directly camera and album etc. ?
Please suggest!
Thank you!
It's not possible to access phone camera using Web app, as the "Web APP" typically runs in the browser of device.
Though there are some frameworks (like Phonegap) allows you to embedd your web app into native container. With this approach and added libraries from such framework you can access some of those native API's and Device Hardware.
One Possible solution is,
Create one app and distribute it using app store
using your webapp, you can connect to above app using url-scheme
http://code.google.com/p/iphone-photo-picker/
go to above link, where you can find complete code for it.

Can you access the iPhone's address book in a Dashcode-designed web application?

I'm writing a web application using Dashcode. Is it possible to access the iPhone address book from within this web application?
Dashcode is just the development environment IDE for generating widgets and iPhone apps and actually write the apps using JavaScript, HTML and CSS. Any app you make will need to sit on a server and be accessed through the mobile browser on the iPhone. So the question is can you/i connect from a web app to the iPhone native applications. Just from a security point of view i would doubt that this is possible or even desirable,
However i have seen suggestions that a native application in x-code could be built that would have a web interface that would be able to talk to the browser but i am not sure how you would engineer that or if it would work.
I suspect a simple solution is to sync your iPh=one contact with Gmail, or similar web app and then access it or write your own server that you sync contacts to. However this is not a general solution i suspect.
Hope this helps even though it is not the answer.

iPhone Web Appication deployment and distribution process

--I haven't develop any iPhone Web Application ever...so i am little bit confuse about that.
--I want to build a Web Application for iPhone which will be made using(CSS+JavaScript).
--I read some where that no approval is required for iPhone Web Application.
is it correct ?
--And if i have made my iPhone Web Application (using CSS+JavaScript)and uploaded at my server.
--and if i want to open it in UIWebView using iPhone SDK simply...
--is this Application is valid for iPhone Web Application portal https://adcweb.apple.com/iphone/index.php or not ?
--how can end users get the Application on their iPhone after submiting to the portal...
--can any one explain me the whole process of iPhone Web Application deployment and distribution process ?
Thanks in advance...
iPhone (and others) have support for "stand alone" web apps. These are web apps that are designed to work offline. These applications are hosted on the web, but along with the application is a manifest file that describes all of the resources that the application will need. These resources are all downloaded to the device.
On the iPhone, to "install" one of these applications, you need to simply bookmark it. When you bookmark the app, the phone asks if you want an icon for it in the standard app area, vs just a bookmark in the browser.
Once bookmarked, the user can simply tap on the icon like any other application. This will launch safari for your application, and it starts using its local resource. There's no reason a standalone application that never touches the internet can't be written. The Safari Reference Library has a lot of information on this.
If you'r building a web application, we talk about something, that does not need to be installed on the iPhone, because it runs inside the browser. So yes, you don't have to go through the approval process, it's just a website optimized for the iPhone. The submission you linked to in your question is to get listed at apple with your web application (I'm not sure about the guidelines for that), it,s not a submission for the app store. You don't have to (and you should not) make use of the SDK by using UIWebView, because that would mean to build an native application which needs approval, has to be installed etc. If your goal is or can reached by building a web application, all the user needs is safari.
You do not need approval for a web application. The iPhone can view any web page through its browser (as long as there's no flash), so just implement your application as you normally would, but design for the smaller screen. The submission form is just for listing in portals (I don't know which portals).
If you want to make a native iPhone application that talks to the server, then you need to sign up for a developer account and develop the application in Objective-C (with the help of UIWebViews, which are essentially embedded browser windows). That will require approval.
What about a web application that needs to be installed. By that I mean an application that consists of a web page (with embedded CSS and Javascript) that uses HTML5's localStorage to work offline. You still need to be able to access the page itself if you lost the connection, i.e. the page needs to be stored locally, because once you are offline, you can't access it from a server outside...

How can I access to the iPhone address book in a web app?

I'm currently developing a web app for my company. In this application, there's a form with input fields containing informations about contacts. I would like to create a button which allows to create a contact in the address book on a click.
Is there anyway to access the address book with JavaScript or other web language ?
For example, on windows and IE we can create an ActiveX object in JavaScript to create contacts in Outlook...
Thanks.
If this turns out to be possible, I'm eating my Mighty Mouse ..
I apologize for the slightly unrelated answer
P.S: to make this answer slightly more related; you could accomplish this by creating a hybrid between a native application and a web app, where the native app will pop-up the address book and then return its data to the web app.
If you create a link that generates a file in the vCard format, the iPhone version of Safari might recognize it as a contact and automatically launch the address book app when they click on the link.
It appears that this would NOT work as of iPhone 2.1 (no vCard support in safari), but it might work in 3.0 - I have seen that people will be able to send vCards via MMS on the iPhone, so maybe they'll work in safari too? I guess you'd just have to try it to find out.