Component that needs to communicate with a local js file

Hi there,

we are developing a web component for our mobile app. We build the app with phoneGap for the login page and the iframe our Servoy app is running in. Now we use a phoneGap plugin which allows us to share stuff with a native socialshare option. The challenge we have right now is that our component needs to talk to a cordova.js file that exist locally on the phone. Servoy don’t know about it. Is there any way we can connect this file to our webcomponent in Servoy?

Thanks in advance

Hi,

If you need to talk to a phonegap plugin you will need a bridge of sorts between the iframe and phonegap native wrapper. There is one web service that’s in development (https://github.com/Servoy/svyPhonegap) that details how to connect to a camera/location plugin.

There also exists a mobile sample solution that uses it. (https://github.com/Servoy/svyMobile)

Basically - in order to connect your particular plugin, you will have to write a simple web service api to communicate to it from within Servoy.

Hi,

Thanks for the advice. With a service we got it up and running

Hi,

i’m fairly new to Servoy and i’m trying to use the Phonegap plugin, i’ve followed the link posted further up that directed me towards a mobile sample of github. The sample readme mentioned that additional libraries are needed to run the sample. I was hoping you could tell me if i’m able to just search github for those libraries or whether I might need to look further afield.

Thanks

Although most of the software is open source and a few of them might be on Github, it’s easier to just get to the binaries from their respective websites:

Phonegap cli:
http://docs.phonegap.com/references/pho … i/install/

Node.JS
https://nodejs.org/en/

Git
https://git-scm.com/

Thanks, that’s just what I needed.