Facebook app settings on PhoneGap application

别等时光非礼了梦想. 提交于 2020-01-01 04:55:10

问题


I have a phonegap application that uses the main facebook-plugin for connecting. I'm also using the phonegap build to directly get the apk/ipa without generating an android/ios project.

Inside the facebook for developers, however, I have to complete some settings for my application that seem to require more than the simple phonegap build. I saw some tutorial in generating the hash key for an android app, but, what should I complete into the "Class Name" field(the activity that facebook will launch) since I don't have any class in my javascript-phonegap code?


回答1:


I have provided screenshots of the config.xml path and the configuration where you will find the package id. `

If you are using cordova from command-line, the default activity class for Cordova android application is CordovaApp.

So for in this case your configuration in Facebook developer should be like this.

Package Name: com.phonegap.helloworld
Default Activity Class Name: com.phonegap.helloworld.CordovaApp

You need to update the package name as per the entry you have in the config.xml

If you are building your app using the Adobe Phonegap Build Service,in that case the default activity name is generated by CamelCase notation of your application name. So Default Activity Test becomes DefaultActivityTest

So your configuration in Facebook developer should look like this.

Package Name: com.phonegap.randomPackage
Default Activity Class Name: com.phonegap.randomPackage.DefaultActivityTest

You can decompile your apk from the site below:

http://www.decompileandroid.com.

Choose the static version(the flash version was not working) and after uploading,you can see the decompiled AndroidManifest.xml file.

This is what I got after decompiling my application apk.

http://www.decompileandroid.com/complete/182864?key=ecb3cec5a9b1418afe5d67f7151b518f




回答2:


If you create android application means, you specified your "activity name" during project creation.That name is your class name.

Enter package name: com.example.proj and Enter class name: Your project activity name and Enter your key hash



来源:https://stackoverflow.com/questions/26600976/facebook-app-settings-on-phonegap-application

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!