Home › Forums › Back End › Trying to add Custom Field data into a PHP function, but isn’t working. › Re: Trying to add Custom Field data into a PHP function, but isn’t working.
June 12, 2013 at 6:45 pm
#138516
Alen
Participant
You are already within php code block there is no need to nest `ID, ‘v_url’, true);
$JSON = file_get_contents(“https://gdata.youtube.com/feeds/api/videos/{$video_ID}?v=2&alt=json”);
$JSON_Data = json_decode($JSON);
$views = $JSON_Data->{‘entry’}->{‘yt$statistics’}->{‘viewCount’};
echo $views;
?>