New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Plugin is not defined when the app is built on PhoneGap Build #411
Comments
Do you use Android phone or emulator? |
i am using android 4.4.2 phone (Lenovo S820) yes it have google play services. |
Ok, is there any error message in logcat? |
Could you show me the whole logcat log? |
"adb logcat" gives me result: i have android platform-tools and tools added in Environment Variables but... |
thanks for the reply, its too late here i will have to read and research tomorrow. |
ok finally i managed to get the log. ok now back to the issue, here is my log file (i will work on my filtering skills next, so sorry for the long log): http://www.fun-kids-games.biz/test/log.txt |
Thanks, @svarc |
ok i will send you the apk and the whole source of my project. will reach you in few seconds. |
@svarc |
oh well :( then i wasted few days for nothing it seems. |
Sorry, I'm planing to support Phonegap Build, but I don't have enough time for it currently. |
Sorry to interrupt, but I use this plugin with Phonegap Build just fine :) In my config.xml:
Works on both Android and iOS. :) |
Thanks good information, @MichaelGooden |
Hello, I am trying to integrate the module in my application but I have exactly the same problem as @svarc .(ReferenceError: plugin is not defined). So I have two questions. |
Please view your app on PhoneGap Build, and go to the "Plugins" tab on your app (Next to "Builds" tab). Do you see |
Hi thank you for your response, android.support.v4 21.0.1 "Android Support v4" So, i the google map plugin are in the list , i hope that i responded to your question. |
Yes, I was referring to the "Adobe® PhoneGap™ Build cloud service". This issue is also specifically about that. If you use my code in your config.xml it will only work if you are using the PhoneGap Build service. This issue will not resolve your problems. Follow all the instructions in the wiki, and if you are still having problems open a new issue :) |
Thank you very much ;-) i'll try tomorow. |
Thanks @MichaelGooden and @wf9a5m75 for your help. i still havent tried what you said but i will do it in the next few days and post the results here. |
Hi, finally the map is working ^^ . I had a SHA1 key mismatch. this link helped me : https://developers.google.com/games/services/android/troubleshooting |
I close this issue at once. |
I had problem with Phonegap Build Service. I used the solution as @MichaelGooden metioned above. Android apk was running perfect but in ios i received the message "Api key is not setted. Please replace 'API_KEY_FOR_IOS' in the platforms/ios/.../...Info.plist with your API key." For some reason, API_KEY_FOR_IOS value was ignored. I used the solution
|
hello, good day, im trying to implement this plugin on my phonegap build app but when I put the follow code the compiler fails:
and the compiler display this: any documentation how to use on phonegap build or has an example? |
Can you try the latest version 1.2.5 first? |
hi, i detect the problem, this plugin is not working with the last version of "Phonegap Build" cli-5.1.1 Android 4.0.2, if I use the old version 3.7 compile OK. I dont know if is a bug of cloud service or of the plugin. |
thank you! working good with @Nipher version. |
i have used the plugin and tried to build through Phonegap build.Map is just displayed as GREY area . |
The plugin works only with wifi. How to use with 3G? |
It works with all network.2G,3G,Wifi. You need to give permission to access On Tue, Jul 7, 2015 at 8:41 AM, Leomhl notifications@github.com wrote:
Thanks and Regards, Prasoon P |
How? It does not work without wi fi. With 3G turned it asks to enable wi fi. |
@007pRASoon did you solve this? I added this to config.xml with no success: <feature name="http://api.phonegap.com/1.0/geolocation"/> pd: I'm using phonegap build service |
@erasmo-marin the url in the name attribute isn't even working though. If you're using the phonegap build cloud services, use it this way. <gap:plugin name="org.apache.cordova.geolocation" version="0.3.10" /> |
@MichaelGooden your solution doesn't work anymore, plugins.cordova.io just got deprecated and can't be used. I tried any other combination, from the one PhonegapBuild offers in his Plugin page (why it's still there? It doesn't load!) to the ones on the npm and the most promising seems this one: https://www.npmjs.com/package/cordova-plugin-googlemaps , that would translate into this on config.xml: plugin name="plugin.google.maps" source="plugins.cordova.io" version="~1.2.4 But this plugin on npmjs doesn't seem to have any version below 1.3.0 and the ones above require some gradle configuration which I couldn't set properly (the prefence called "android-minSdkVersion" doesn't do anything), probably requires an AndroidManifest tweak. I'm really puzzled about the state of this, isn't anyone using google map on phonegap build? |
I tried installing it with Phonegap Build today and got the following error:
This is the page the error links to but I don't see anything to fix it: Adding preference name="android-build-tool" value="gradle" gave the following error (although shouldn't be required because from cli-5.1.1 onwards, gradle should be the default build): |
@lengoyvaerts I have no problem with "Oh geez. Your build failed ...". In my case, the building process works. |
@MilestoneCMS Yes, I found that gradle solution today on Twitter too :D but my problem is that I have to use a cordova version below 4, because of Drupalgap requiring it, so I can't use the last plugin with the gradle fix. I also found a previous version of the same plugin (forked) so it could work with Phonegap 3.7.0, but then I have the "Oh geez". If anyone is interested I opened a thread in the Phonegap forum: |
Hi, I am using the phonegap google map plugin that you have mentioned, I use the online phonegap to build my apk Just wondering where My config.xml should sit, in the root directory, res/xml/config.xml, www/config.xml, or root directory. where should My index.xml sit in the root directory or www/index.html or root directory where .cordova.CORDOVA file should sit, I have in the same directory as my index.html, and where the following files should sit. I have them in my root directory.
also if I could get a copy of someone's index.html for code for the google maps plugin At the moment I am getting a blank screen, but the google logo appears in the lower left hand corner. < script type="text/javascript" src="cordova.js">< /script> in my index.html and the ".corodva.CORDOVA" file sitting in the same directory which is the www directory. If I dont have this line of code I dont even get a blank google map screen, nothing appears at all If I could get some answers on this from someone who has the plugin working that would be great. Thanks |
Hello there.
I have seen many issues reported for this same problem but none of them solves or suits the issue i encounter.
I installed the plugin automatically and when i type "phonegap plugin list" i get this result:
android.support.v4 21.0.1 "Android Support v4"
com.google.playservices 21.0.0 "Google Play Services for Android"
plugin.google.maps 1.2.4 "phonegap-googlemaps-plugin"
plugin.http.request 1.0.0 "phonegap-http-request"
This is how i call the map:
var map;
var div = document.getElementById("map_canvas");
map = plugin.google.maps.Map.getMap(div);
I get this error:
ReferenceError: plugin is not defined
map = plugin.google.maps.Map.getMap(div);
The app is compiling without error, the map div (map_canvas) is shown but the map is blank no buttons no nothing.
Anyone have any idea about how to fix this?
Thanks in advance and best wishes.
The text was updated successfully, but these errors were encountered: