function check_link url resp json_decode vk utils checkLink array url

1
2
3
4
5
6
function check_link($url){
$resp = json_decode(vk("utils.checkLink", array("url" => $url)), true);
if($resp["response"]["status"] == "processing") check_link($url);
$status = ($resp["response"]["status"] == "banned")?0:1;
return $status;
}