2
votes

I've installed Phonegap using the npm and my app is working great, except when I call window.open to launch a website it does not give me the footer with the done button so my app get's stuck on the called web page.

I am using XCode to build an ios app.

I've used npm to add the InAppBrowser plugin. It added the to to the config.xml.

I've added the site to my whitelist in config.xml. The site opens fine, just without the done button/footer.

It added the InAppBrowser plugin entry to: /#myapp#/platforms/#platform#/www/cordova_plugins.js

It added the InAppBrowser plugin folder in /#myapp#/platforms/#platform#/plugins/

The related SRC files for InAppBrowser are in the platform folder as well (for example IOS plugin src files are: /#myapp#/platforms/#platform#/#appname#/Plugins/)

I added a console.log function to InAppBrowser.js to confirm that the plugin is loaded, but it does not generate a log entry.

I've tried many things to get the footer/done button to show without any success, but I seem to be missing something here.

1

1 Answers

1
votes

I solved this problem by recreating the Xcode project using cordova (instead of phonegap). I went through all of the solutions several times with no luck, so I used the terminal to build a new cordova project, added the InAppBrowser to the project, then copied my code and assets from the old project to the new one. Launched the app on my ipad and it all worked just fine.

I don't suspect it's a problem with Phonegap 3.1.0. I think there was a project issue that kept it from working and starting over with a clean project did the trick.

All is well.

One note is that I saw postings that reported cordova interrupts the console.log function, so be careful with that. Alerts work just fine.