Advertisement
Streamingdb-net

YouTube Playlist V0.2

Oct 12th, 2011
98
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.78 KB | None | 0 0
  1.     <?php
  2.     $videos = get_post_meta($post->ID, "youtube", true);
  3.       if ($videos != "")
  4.       {
  5.         echo '<div id="playlist">';
  6.         echo '<div class="s_playlist">';
  7.         echo '<div id="playlist_t">PLAYLIST <strong>1</strong></div>';
  8.         echo '<div class="cdiv"></div>';
  9.         echo '</div>';
  10.         echo '<div class="description">';
  11.         echo '<ul>';
  12.         $videos = nl2br($videos);
  13.         $videos = explode("<br />", $videos);
  14.         foreach ($videos as $i => $video)
  15.         {
  16.         // output del video
  17.         echo '<li><a href="'.$video.'">'. ($i + 1) .'</a></li>';
  18.         }
  19.         echo '</ul>';
  20.         echo '<div class="cdiv">';
  21.         echo '</div>';
  22.         echo '<br>';
  23.         echo '</div>';
  24.         echo '</div>';
  25.       }
  26.     ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement