This is my first facebook app I am trying to create. I started reading about it, I downloaded the SDK, looked for examples and in every code I found they start with importing a facebook.php file that is missing from the SDK folder I downloaded from facebook - https://developers.facebook.com/docs/php/gettingstarted/4.0.0. Even on github https://github.com/facebook/facebook-php-sdk the shown code starts with require 'facebook-php-sdk/src/facebook.php';. But once again, this file doesn't exists. How do I use the SDK?
You are looking at the wrong version on github, this is v4: https://github.com/facebook/facebook-php-sdk-v4
It works completely different, as you can see in the example code. You don´t include a "facebook.php" anymore, you either use Composer or you load the autoloader.php in the src folder of the SDK.
Here´s a basic tutorial for the new PHP SDK: http://www.devils-heaven.com/facebook-php-sdk-4-0-tutorial/
Related
According to https://www.movesense.com/news/2020/02/movesense-showcase-ios-app-is-now-open-source/ the showcase app source is open source. But the source code that’s there in the repo is at least couple of versions behind in terms of UI.
Is there an updated repo location for the latest? Our client is looking at the app in AppStore thinking the source code should be the same.
Well, the source code in the repository is exactly the same as has been used for generating and compiling the app store version. Could you please make sure you are using the master branch of this repo: https://bitbucket.org/suunto/movesense-mobile-lib/ ?
Also, please make sure that you are opening the folder MovesenseShowcase in xcode, not IOS-example (which is the old example app for iOS)
In addition, please make sure you are using Xcode 11 (latest) and following the instructions in readme.md
I am trying to download fbsdk v5 from facebook sdk downloads. Here it refers to this github page for download. And from the github page it refers back to the previous same page facebook sdk downloads.
It's unending loops of references.
Can someone help me with a link to the download of fbsdk v5 directly?
You can download by clicking the button clone or download simply
If you want to use facebook-sdk in your react-native project i would highly recommend to use react-native-fbsdk package by npm instead of download and use.
I'm trying to implement mobile application using Ionic. I'm following this, but unfortunately logging in doesn't work on real device. It works fine in the browser and the emulator. I did every step from the tutorial, I did the tutorial 2-3 times and still get the same error.
I am logged in successfully on my device but then I see the following screen:
I already have both urls as redirect urls in my application settings in FB.
http://localhost:5000/oauthcallback.html
https://www.facebook.com/connect/login_success.html
I tried to debug OpenFB with alerts. I can see "cordova events" alert but then I have alerts on the first lines of loginWindow_loadStartHandler and loginWindow_exitHandler but they are not executed. I guess that the problem is there but I have no idea how to fix it.
if (runningInCordova) {
alert("cordova events");
loginWindow.addEventListener('loadstart', loginWindow_loadStartHandler);
loginWindow.addEventListener('exit', loginWindow_exitHandler);
}
Also I have some questions about Ionic and Phonegap.
I use Ubuntu and I am trying to build iOS and Android applications.
My application's structure is:
app/
hooks/
platforms/
plugins/
scss/
www/
Also I have InAppBrowser plugin:
cordova plugin add org.apache.cordova.inappbrowser
but this plugin is not part of app/www folder.
I am trying to build a phonegap application in their site. I made a .rar file of the app/www folder content and upload it. Everything seems to be fine. But in Phonegap site when I click PLUGINS, I see This application has no plugins. How should I add inappbrowser to the application, maybe that is the reason why my FB authentication doesn't work. If I build the whole app folder, again I see the same message - This application has no plugins.
So when create an archive file of the content for Phonegap, which folder I should archive - the whole app folder with all subfolders or only app/www? What is the correct flow? Also how crossplatform app should now about added plugins?
I ran into this issue today, if someone is still looking for the solution for this:
loginWindow.addEventListener('loadstart',
loginWindow_loadStartHandler);
is implemented in the js file, but the loadstart event never fires on my Android (but works on WindowsPhone cordova javascript app), instead i added:
loginWindow.addEventListener('loadstop',
loginWindow_loadStartHandler);
,which works on both Android and WP (with InAppBrowser 1.2.0), IOS test is still ahead.
Related question: How do I implement Facebook Mobile Install Ad tracking in Phonegap/Cordova project?
I have a working cordova/phonegap application. I would like to track the APP install using the plugin facebook. I installed the cordova facebook connect plugin with:
cordova plugin add https://github.com/phonegap/phonegap-facebook-plugin.git --variable APP_ID="myappid" --variable APP_NAME="myappname"
The plugin is installed and usable as this report 'true':
alert('fb plugin usable: ' + typeof facebookConnectPlugin != 'undefined')
However I am no seeing anything in the "Most recently logged events" in the facebook developer section for this app. I added the correct Package Name and Class Name in the settings but the events are not just showing up.
Is there anything that I am missing or more info that I can provide ? I cannot find a good tutorial on this that explains the full process.
Should the APP install event just be logged by adding the plugin without any JS call in the app?
I dug a bit in the plugin implementation and noted the activateApp was not implement at all. I cloned the repo and add the functionality for Android [following the FB guide for android ]:
The modifications required on the code are: code changes in plugin and : how to use in the JS code. In this way I can just call
facebookConnectPlugin.activateApp(fb_success, fb_fail);
where the callbacks are just dummy empty function.
and the FB is SDK tracks when there is an installation. I noticed however that the events are generated only when there is a FB app installed on the device [do not know if this is supposed to be like that].
UPDATE
Probably my solution is old, I guess that now the official plugin for Facebook has already the feature implemented directly without the need of any additional customization in the JS files or touching the Java files.
I am following a tutorial on how to enable push notifications in a Cordova project on iOS.
If I use the sample project that the author provided, everything is in place and works.
However I need to use the latest Cordova version so I started to make my own project. The Cordova project is created correctly. The problems start when I try to install the push notifications plugin.
On the tutorial the author says to make some changes to the cordova.plist file but why on earth the .plist file doesn't exist in the latest version of Cordova?
Is there another way to enable the plugin? We don't need the .plist?
I had the exact same problem. Got stuck at the same place. This is what I did
1- Install the Plugin using the CLI - phonegap local plugin add https://github.com/phonegap-build/PushPlugin.git
2- Since i could not find the PLIST adding the code to the AppDelegate.m would just create errors. So i found the following link:
Cordova 2.5.0 - Errors after referencing appDelegate.m to PushPlugin
3- Within the above link there is a sample of an appdelegate.m which i copied and replaced in my code. THis way i dont have to play worry about the plist.
4- I copied the rest of the JS and it worked immediately. Hope this helps.
you managed it how to solve the problem?
you have to make the changes in the config.xml-file
add: plugin
name="PushPlugin" and value="PushPlugin
inside config.xml
then add this to you your AppDelegate.m
https://github.com/hollyschinsky/PhoneGapBuildPushProject2/blob/master/PhoneGapBuildPushApp2/Classes/AppDelegate.m
Hope this was helpful - I'm on the same tutorial but couldn't manage the next step - maybe we could help each other a little