P
Phillip Molly Malone
Guest
Hey Bal, Just tried the social share plugin and was able to get it working. I am going to add a document I built for adding a local notification plugin that should give you the basic steps if you substitute in the Social Share plugin in for the Local Notification plugin. So the differences are (number represents the point in the attached document that changes): 1) Social Sharing available at https://github.com/EddyVerbruggen/SocialSharing-PhoneGap-Plugin. I downloaded and used the most recent release. 4) The folder to create should be "nl.xservices.plugins.SocialSharing" 5) The .js file would be "SocialSharing.js" and its in the "SocialSharing-PhoneGap-Plugin-4.3.8\www" directory. 6) The top code to add is: ------------------- cordova.define("nl.xservices.plugins.SocialSharing", function (require, exports, module) { =========== and should go at the start of the file. The bottom code to add is the same. 8) The code to add in the cordova_plugin.js file is: --------------------- , { "file": "plugins\\nl.xservices.plugins.SocialSharing\\www\\SocialSharing.js", "id": "nl.xservices.plugins.SocialSharing", "clobbers": [ "window.plugins.socialsharing" ] } ============ 9) The text for config.xml would be: ------------------- feature name="SocialSharing" param name="android-package" value="nl.xservices.plugins.SocialSharing" / /feature =========== 10) The directory structure would be "nl\xservices\plugins" 11) There is only one java file to upload for the Social Sharing plugin: SocialSharing.java 13) the code to add to the AndroidManifest.xml file is: --------- uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/ ============ 14) Not needed 20) Code in here could be something like: ------------ window.plugins.socialsharing.share('My message', null, null, 'http://www.x-services.nl'); ========= You should be able to compile this for Android and run it on an Android device. Let me know if this helps (and in fact if it makes any sense at all. It is hard to explain. If push comes to shove, perhaps I can share my test project with you).
Continue reading...
Continue reading...