예제 #1
0
 function initialize($Media)
 {
     if (isset($Media->objects['MP3_Id'])) {
         return true;
     }
     if (!isset($Media->file)) {
         return false;
     }
     $Object = new MP3_Id();
     $Object->read($Media->file);
     $Object->study();
     $Media->objects['MP3_Id'] =& $Object;
     return true;
 }
예제 #2
0
파일: view.php 프로젝트: chegestar/catroxs
    }
    $im1 = ImageCreateTrueColor($tn_width, $tn_height);
    imagecopyresized($im1, $im, 0, 0, 0, 0, $tn_width, $tn_height, $width, $height);
    $path = "{$filesroot}/graftemp";
    $imagnam = "{$path}/{$namefile}.temp.png";
    imageJpeg($im1, $imagnam, $quality);
    echo "<p><img src='" . $imagnam . "' alt=''/></p>";
    imagedestroy($im);
    imagedestroy($im1);
    @chmod("{$imagnam}", 0644);
    echo $widthf . ' x ' . $heightf . 'px<br/>';
}
if ($prg == "mp3") {
    $id3 = new MP3_Id();
    $result = $id3->read("{$adrfile['adres']}/{$adrfile['name']}");
    $result = $id3->study();
    echo '<p>';
    if (!empty($id3->artists)) {
        echo '<div><b>' . $lng_dl['artist'] . ':</b> ' . $id3->artists . '</div>';
    }
    if (!empty($id3->album)) {
        echo '<div><b>' . $lng_dl['album'] . ':</b> ' . $id3->album . '</div>';
    }
    if (!empty($id3->year)) {
        echo '<div><b>' . $lng_dl['released'] . ':</b> ' . $id3->year . '</div>';
    }
    if (!empty($id3->name)) {
        echo '<div><b>' . $lng['title'] . ':</b> ' . $id3->name . '</div>';
    }
    echo '</p>';
    if ($id3->getTag('bitrate')) {