login with facebook open in Android facebook Application in PHP?
Get the solution ↓↓↓I was implement login with Facebook in PHP It's perfect Works But i want if website open in mobile browser then redirect in Mobile Facebook Application if Not then mobile browser. How can Do ?
here some code
require_once __DIR__ . '/Facebook/autoload.php'; // download official fb sdk for php @ https://github.com/facebook/php-graph-sdk
$fb = new Facebook\Facebook([
'app_id' => '*****************',
'app_secret' => '*******************',
'default_graph_version' => '***',
]);
$helper = $fb->getRedirectLoginHelper();
$loginUrl = $helper2->getLoginUrl('URL', $permissions);
//here login with facebook button
<a href="<?php echo $loginUrl ?>" class="fbblue">Log in with Facebook!</a>
This code redirect only facebook in browser.
Help me .
Thnakyou
Share solution ↓
Additional Information:
Link To Answer People are also looking for solutions of the problem: a non well formed numeric value encountered
Didn't find the answer?
Our community is visited by hundreds of web development professionals every day. Ask your question and get a quick answer for free.
Similar questions
Find the answer in similar questions on our website.
Write quick answer
Do you know the answer to this question? Write a quick response to it. With your help, we will make our community stronger.