echo '<div style="text-align: center">' . $title . '<br/> <img src="' . $thumbnail_url . '" border="0" hspace="2" vspace="2"></div><br/>'; echo '<table class="table table-striped table-bordered"> <thead> <tr> <th style="text-align: center">Format </th> <th style="text-align: center">Size/Quality</th> <th style="text-align: center">Download</th> </tr> </thead> <tbody>'; /* now that we have the array, print the options */ for ($i = 0; $i < count($avail_formats); $i++) { # Get the filesize, to make sure we can download it for the mp3 conversion $file_size = remotefileSize($avail_formats[$i]['url']); echo ' <tr> <td style="text-align: center">' . $avail_formats[$i]['type'] . '</td> <td style="text-align: center">' . $avail_formats[$i]['quality'] . '</td> <td class="td-actions" style="text-align: center"> <a class="btn btn-small btn-success" data-toggle="tooltip" title="Download Video" href="download.php?mime=' . $avail_formats[$i]['type'] . '&title=' . urlencode($my_title) . '&token=' . base64_encode($avail_formats[$i]['url']) . '"><i class="btn-icon-only icon-film"></i></a>'; # Display the MP3 download button if a CloudConvert API key has been set if ($config['cloud_convert_api_key'] != 'INSERT YOUR API KEY HERE' && !empty($config['cloud_convert_api_key']) && $avail_formats[$i]['type'] != 'video/3gpp' && $file_size > 0 && $file_size) { echo ' <a class="btn btn-danger btn-small" data-toggle="tooltip" title="Download MP3" href="download.php?type=mp3&mime=' . $avail_formats[$i]['type'] . '&title=' . urlencode($my_title) . '&token=' . base64_encode($avail_formats[$i]['url']) . '"><i class="btn-icon-only icon-music"> </i></a>'; } echo '</td></tr>'; } echo '</ul>'; } ?>
function redirect($shortcut) { $array = getData($shortcut); if ($array) { $destination = trim($array['url']); clickCount($shortcut, $array); } else { include "config/user.php"; $error = empty($conf['redirect']) ? curPageURL() : $conf['redirect']; header('Location: ' . $error . ''); exit; } $xml = simplexml_load_file($destination, 'SimpleXMLElement', LIBXML_NOCDATA); foreach ($xml->channel->item as $item) { // get children for namespace prefixed 'media' $media = $item->children('media', true); $preview = $media->group->content[0]->attributes(); $video1 = $media->group->content[1]->attributes(); // $video2 = $media->group->content[2]->attributes(); $cont = remotefileSize('' . $video1['url'] . ''); // $cont2 = remotefileSize(''.$video2['url'].''); } if (!empty($video1)) { echo ' <br/> <center> <img style="max-width: 100px;" src="' . $preview['url'] . '"/> </center> <table class="u-full-width"> <thead> <tr> <th>Title</th> <th>File</th> <th>Size</th> <th>Addon</th> </tr> </thead> <tbody> <tr> <td>' . $item->title . '</td> <td>MP4/Video</td> <td>' . formatBytes($cont) . '</td> <td>' . $item->pubDate . '</td> </tr> </tbody> </table> <center> <a class="button button-primary" href="' . $video1['url'] . '">Download</a> </center> <br/> '; include 'data/download'; } else { echo "Video Sedang Di Proses"; } }