Kodlar:
// get feed URL for related videos
$entry->registerXPathNamespace('feed', 'http://www.w3.org/2005/Atom');
$nodeset = $entry->xpath("feed:link[@rel='http://gdata.youtube.com/schemas/2007#video.related']");
if (count($nodeset) > 0) {
$obj->relatedURL = $nodeset[0]['href'];
}
// read 'related videos' feed into SimpleXML object
// parse and display each video entry
if ($video->relatedURL) {
$relatedFeed = simplexml_load_file($video->relatedURL);
echo "";
foreach ($relatedFeed->entry as $related) {
$relatedVideo = parseVideoEntry($related);
echo "";
}
}