Ai fix vơi
<?php
include 'confizz.php';
$sql = "SELECT token, idfb, type FROM BotCamsuc ORDER BY RAND()";
$result = mysql_query($sql);
$list_type = array('LIKE','LOVE','HAHA','WOW','SAD','ANGRY');
$type = $list_type[array_rand($list_type)];
while($r = mysql_fetch_assoc($result)){
$feed = json_decode(cURL('https://graph.fb.me/me/home?access_token='.$r['token'].'&limit=15&fields=id'),true);
for($i = 0; $i < 10; $i++){
if($r['type'] != 'RANDOM'){
cURL('https://graph.fb.me/'.$feed['data'][$i]['id'].'/reactions?access_token='.$r['token'].'&type='.$r['type'].'&method=post');
}else{
cURL('https://graph.fb.me/'.$feed['data'][$i]['id'].'/reactions?access_token='.$r['token'].'&type='.$type.'&method=post');
}
}
}
function cURL($url){
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, false);
return curl_exec($ch);
}
?>