Uri
Uri

Reputation: 26966

Loading index.html remotely and using the contacts API

I'm building an application using cordova, and loading my index.html from a remote server (the index.html I'm supplying to the phonegap online builder is a simple redirect page to the server address)

When trying to use the contacts API, I'm getting ContactFindOptions is undefined.

I have a refrence for cordova.js in the top of my HEAD like so: <script src="cordova.js" type="text/javascript"></script> but the actual file, if I understand correctly, is supposed to be created by the app itself (maybe it only works when index.html is local?).

I'm guessing cordova.js didn't load properly. Any ideas to fix it?

Upvotes: 0

Views: 178

Answers (1)

Uri
Uri

Reputation: 26966

Guess you can't do that on cordova. If you want to load index.html from a remote server you have to give up the API...

Source: http://community.phonegap.com/nitobi/topics/phonegap_functions_from_external_website

Upvotes: 0

Related Questions