...:: Avoue Tu Kiffe ::... Index du Forum
...:: Avoue Tu Kiffe ::...

 
...:: Avoue Tu Kiffe ::... Index du ForumFAQRechercherS’enregistrerConnexion

:: Facebook Api Php Login ::

 
Poster un nouveau sujet   Répondre au sujet    ...:: Avoue Tu Kiffe ::... Index du Forum -> Ghosts ->
Sujet précédent :: Sujet suivant  
Auteur Message
stexen


Hors ligne

Inscrit le: 12 Mai 2016
Messages: 79
Localisation: Strossburi
Masculin

MessagePosté le: Mar 9 Jan - 18:35 (2018)    Sujet du message: Facebook Api Php Login Répondre en citant




Facebook Api Php Login
> DOWNLOAD (Mirror #1)










If you understand how it works, you can use this function (a bit modified) as a social feature forthe comments form on your WordPress website. Now I create a GraphObject fromthe response and the script outputs the data to the browser. ' 1 echo ' ' . ' ; This one is used to see that it works, the example file isnt a full working application or script. The old version 1.0 will have an EOT in April 2015. ' '; $msgid = $graphObject->getProperty('id'); } catch ( FacebookRequestException $e ) { // show any error for this facebook request echo 'Facebook (post) request error: '.$e->getMessage(); } This part of the script does the following: If $session exists, the scriptstores the object inside a PHP session variable and a new Facebook session object is created. By clicking or navigating the site, you agree to allow our collection of information on and off Facebook through cookies. it seems i cant get a session :S Reply Olaf Lederer Do you authorized the session using your own Facebook account? The example script is just a demo not an application& if it works on my demo page, the same code should work for you, too. Reply mncedisi Hi Problem solved, i didnt destroy the last user session set on my application. Reply mary I am trying to upload photo through api but it showing me this error. The GET request is almost the same as the previous POST request. Before you can post to the Facebook users time-line, the user has to authorize the application first. Cloudways Protect your WordPress site against bad bots ServerPilot = Great VPS Hosting for WordPress Websites Tutorials & CodeWeb Development Tutorials PHP Classes & Scripts PHP Code Snippets Demos & examples Premium website templates This website is hosted by: Web Development BlogUsing Elasticsearch with PHP a simple guideHow to use Mailgun with MyMail the newsletter plugin for WordPress?Simple PHP Code Debugging Twitter Google RSS 2018 finalwebsites.com Powered by WordPress . Share what's new in your life on your Timeline. SDKsiOS SDKAndroid SDKJavaScript SDKPHP SDKUnity SDK. By clicking or navigating the site, you agree to allow our collection of information on and off Facebook through cookies. Facebook API PHP example Create inside yournew directory a new PHP file and add the following code: PHP validate() ) $session = null; } catch ( Exception $e ) { // catch any exceptions and set the sesson null $session = null; echo 'No session: '.$e->getMessage(); } } elseif ( empty( $session ) ) { // the session is empty, we create a new one try { // the visitor is redirected from the login, let's pickup the session $session = $helper->getSessionFromRedirect(); } catch( FacebookRequestException $e ) { // Facebook has returned an error echo 'Facebook (session) request error: '.$e->getMessage(); } catch( Exception $e ) { // Any other error echo 'Other (session) request error: '.$e->getMessage(); } } 1234567891011121314151617181920212223242526272829303132 / initialize your app using your key and secretFacebookSession::setDefaultApplication($apikey, $apisecret);// create a helper opject which is needed to create a login URL// the $redirectloginurl is the page a visitor will come to after login$helper = new FacebookRedirectLoginHelper( $redirectloginurl);// First check if this is an existing PHP sessionif ( isset( $SESSION ) && isset( $SESSION['fbtoken'] ) ) { // create new session from the existing PHP sesson $session = new FacebookSession( $SESSION['fbtoken'] ); try { // validate the accesstoken to make sure it's still valid if ( !$session->validate() ) $session = null; } catch ( Exception $e ) { // catch any exceptions and set the sesson null $session = null; echo 'No session: '.$e->getMessage(); }}elseif ( empty( $session ) ) { // the session is empty, we create a new one try { // the visitor is redirected from the login, let's pickup the session $session = $helper->getSessionFromRedirect(); } catch( FacebookRequestException $e ) { // Facebook has returned an error echo 'Facebook (session) request error: '.$e->getMessage(); } catch( Exception $e ) { // Any other error echo 'Other (session) request error: '.$e->getMessage(); }} After the application is initiated thehelper object is created. Enter the domain were your web application is hosted or better click the Add Platform button -> Website and enter the web application URL (directory) where your web application is located. This object is used later if a valid Facebook session is messing. All you can do is trial and error Reply Emily Hi I have exactly same code, but I keep getting error Facebkook (post) request error: Invalid parameter. Note the demo/application is just and example how you can implement such a feature in your own application. Great tutorial! Do you have an update for SDK v5 ? Theres no more FacebookSession class or dont know how to adapt the code to newest SDK. After the app is created, click on Settings in the left menu. Check theFacebook API tutorial demo page to see this PHP code in action. printr( $graphObject2, 1 ) . .. Do you know if the error comes from Facebook or your script? Reply Emily Yes, I did. BackSign UpCreate a Page for a celebrity, band or business.English (US)NederlandsFryskPolskiTrkeDeutschFranais (France)EspaolPortugus (Brasil)ItalianoSign UpLog InMessengerFacebook LiteMobileFind FriendsPeoplePagesPlacesGamesLocationsCelebritiesMarketplaceGroupsRecipesSportsLookMomentsInstagramLocalAboutCreate AdCreate PageDevelopersCareersPrivacyCookiesAd ChoicesTermsHelpSettingsActivity Log Facebook 2018. Jump toSections of this pageAccessibility HelpPress alt + / to open this menuRemoveTo help personalize content, tailor and measure ads, and provide a safer experience, we use cookies. Find more of what you're looking for with Facebook Search. if I only put message, it will work. Reply Mohza Hello there, I have followed your script and also have create my app on the Facebook developer side. I have read several docs in Facebook developer page but I lost, dont really know where to start. Do you check the API manual? The method you need is different from the one Ive used for the tutorial. You can install the SDK using Composer or download the PHP SDK and upload the files like Idid. Thanks you so much Olaf Lederer Hi Emily, The Graph API is very limited in what you can post, posting an image is not always possible. Setting up a Facebookapplication Before youre able to start, its necessary to have a Facebook account and a web hosting account. Facebook (post) request error: (#100) picture is not properly formatted Reply Olaf Lederer Hi Mary, just check the Facebook API docs and solve the error: picture is not properly formatted Reply Submit a Comment Cancel reply Your email address will not be published. Nextwe do a request to Facebook that will post the link including the message 5a02188284
embarrassing things to like on facebookw890i facebook appfacebook chat head videohow to make a facebook account into a pagefake likes on facebook linkserver facebook proxyfacebook de password songis there a facebook like appdownload facebook full setupphoto stalker facebook application


Revenir en haut
Publicité






MessagePosté le: Mar 9 Jan - 18:35 (2018)    Sujet du message: Publicité

PublicitéSupprimer les publicités ?
Revenir en haut
Montrer les messages depuis:   
Poster un nouveau sujet   Répondre au sujet    ...:: Avoue Tu Kiffe ::... Index du Forum -> Ghosts -> Toutes les heures sont au format GMT + 1 Heure
Page 1 sur 1

 
Sauter vers:  

Index | Panneau d’administration | forum gratuit | Forum gratuit d’entraide | Annuaire des forums gratuits | Signaler une violation | Conditions générales d'utilisation
onyx © theme by larme d'ange 2006
Powered by phpBB © 2001, 2005 phpBB Group
Traduction par : phpBB-fr.com