Jump to content

I want php to work with YOUTUBE!!! BRAIN explode()


jeger003

Recommended Posts

hey peeps,

I am trying to get my site to display related youtube videos under the main video

 

here is what i have

$query=mysql_query("SELECT title,mp3ID,youtube_ID FROM songs ORDER BY RAND() LIMIT 10 ") or die("Error Occured");
$left = true;
while($row=mysql_fetch_array($query))
{
if ($left)
{
echo "<tr>";
}
echo "<td align='justify' width='100%' cellspacing='2' cellpadding='2' >";
echo "<td><img src='http://img.youtube.com/vi/".$row['youtube_ID']."/default.jpg'></td>";
echo "<td nowrap><a href='/music.php?id=".$row['mp3ID']."'>".$row['title']."</a></td>";
echo"</td>";
if (!$left)
{
echo"</tr>";
}
$left = !$left;
}
?>

 

this is basic info of how i am able to get youtube video titles and image....i want to use the same youtube.com video ID To get related videos

 

 

please help!!

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.