Skip to content

Instantly share code, notes, and snippets.

@monokaijs
Created January 4, 2019 06:39
Show Gist options
  • Save monokaijs/9782c7e9a5607c4cb72049bf215c0f0a to your computer and use it in GitHub Desktop.
Save monokaijs/9782c7e9a5607c4cb72049bf215c0f0a to your computer and use it in GitHub Desktop.
<?php
$username = "";
$password = "";
$data = array(
"api_key" => "3e7c78e35a76a9299309885393b02d97",
"email" => $username,
"format" => "JSON",
"locale" => "vi_VN",
"method" => "auth.login",
"password" => $password,
"return_ssl_resources" => "0",
"v" => "1.0"
);
foreach($data as $key => $value){
$sig .= "$key=$value";
}
$sig .= 'c1e620fa708a1d5696fb991c1bde5662';
$sig = md5($sig);
$data['sig'] = $sig;
echo file_get_contents('https://api.facebook.com/restserver.php?'.http_build_query($data));
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment