|
From: FlorinCB <ory...@us...> - 2008-09-10 13:55:55
|
Update of /cvsroot/mxbb/mx_music/music_box/modules In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv28153/music_box/modules Modified Files: music_cat.php music_page.php music_song.php Log Message: fix Index: music_cat.php =================================================================== RCS file: /cvsroot/mxbb/mx_music/music_box/modules/music_cat.php,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** music_cat.php 10 Sep 2008 12:26:18 -0000 1.13 --- music_cat.php 10 Sep 2008 13:55:49 -0000 1.14 *************** *** 876,885 **** { //$template->assign_block_vars('songrow.mod', array()); ! $template->assign_block_vars('songrow.x-mod', array()); $url_download = mx_append_sid(this_mo_mxurl("music_mode=music_download&song_id=$song_id")); $url_video = $music_root_path . 'modplayer.swf'; $mime_type= 'audio/x-' . $song_filetype; //application/x-mplayer2 //$row_type = 'mod'; ! $row_type = 'x-mod'; } else if ( ( $song_filetype == '.jpg' ) || ( $song_filetype == '.gif' ) || ( $song_filetype == '.png' ) ) --- 876,893 ---- { //$template->assign_block_vars('songrow.mod', array()); ! $template->assign_block_vars('songrow.xmod', array()); $url_download = mx_append_sid(this_mo_mxurl("music_mode=music_download&song_id=$song_id")); $url_video = $music_root_path . 'modplayer.swf'; $mime_type= 'audio/x-' . $song_filetype; //application/x-mplayer2 //$row_type = 'mod'; ! $row_type = 'xmod'; ! } ! else if ( ( $song_filetype == '.mp3' ) ) ! { ! $template->assign_block_vars('songrow.flv', array()); ! $url_download = mx_append_sid(this_mo_mxurl("music_mode=music_download&song_id=$song_id")); ! $url_video = $music_root_path . 'mediaplayer.swf'; ! $mime_type= 'audio/x-mpeg'; //application/x-mplayer2 ! $row_type = 'flv'; } else if ( ( $song_filetype == '.jpg' ) || ( $song_filetype == '.gif' ) || ( $song_filetype == '.png' ) ) *************** *** 1154,1158 **** case '.xm': $url_song = PORTAL_URL. str_replace('./', '/', MUSIC_UPLOAD_PATH) . $thissong['song_filename']; ! break; default: --- 1162,1170 ---- case '.xm': $url_song = PORTAL_URL. str_replace('./', '/', MUSIC_UPLOAD_PATH) . $thissong['song_filename']; ! break; ! ! case 'mp3': ! $url_song = PORTAL_URL. str_replace('./', '/', MUSIC_UPLOAD_PATH) . $thissong['song_filename']; ! break; default: *************** *** 1403,1407 **** 'FLV' => 'flv', 'MOD' => 'mod', ! 'X-MOD' => 'x-mod', 'IMG' => 'img', 'MEDIA' => 'media', --- 1415,1419 ---- 'FLV' => 'flv', 'MOD' => 'mod', ! 'XMOD' => 'xmod', 'IMG' => 'img', 'MEDIA' => 'media', Index: music_page.php =================================================================== RCS file: /cvsroot/mxbb/mx_music/music_box/modules/music_page.php,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** music_page.php 10 Sep 2008 06:05:24 -0000 1.9 --- music_page.php 10 Sep 2008 13:55:49 -0000 1.10 *************** *** 131,135 **** } ! if ( $thissong['song_imagename'] == '' ) { $img_id = $song_image_default; --- 131,135 ---- } ! if ( !$thissong['song_imagename'] ) { $img_id = $song_image_default; *************** *** 140,144 **** } ! if ( $thissong['song_url'] == '' ) { $song_filetype = substr($thissong['song_filename'], strlen($thissong['song_filename']) - 3, 3); --- 140,144 ---- } ! if ( !$thissong['song_url'] ) { $song_filetype = substr($thissong['song_filename'], strlen($thissong['song_filename']) - 3, 3); *************** *** 296,305 **** $url_video = $music_root_path . 'mediaplayer.swf'; } ! else if ( ( $song_filetype == 'mod' ) || ( $song_filetype == 's3m' ) || ( $song_filetype == 'ult' ) || ( $song_filetype == '.xm' ) ) { $template->assign_block_vars('mod', array()); ! $url_download = mx_append_sid(this_mo_mxurl("music_mode=music_download&song_id=$song_id")); $url_video = $music_root_path . 'modplayer.swf'; ! $row_type = 'mod'; } else if ( ( $song_filetype == 'jpg' ) || ( $song_filetype == 'gif' ) || ( $song_filetype == 'png' ) ) --- 296,324 ---- $url_video = $music_root_path . 'mediaplayer.swf'; } ! else if ( ( $song_filetype == 'mod' ) ) { $template->assign_block_vars('mod', array()); ! $url_download = mx_append_sid(this_mo_mxurl("music_mode=music_download&song_id=$song_id")); $url_video = $music_root_path . 'modplayer.swf'; ! $mime_type= 'audio/x-' . $song_filetype; //application/x-mplayer2 ! $row_type = 'mod'; ! } ! else if ( ( $song_filetype == 's3m' ) || ( $song_filetype == 'ult' ) || ( $song_filetype == '.xm' ) ) ! { ! //$template->assign_block_vars('songrow.mod', array()); ! $template->assign_block_vars('xmod', array()); ! $url_download = mx_append_sid(this_mo_mxurl("music_mode=music_download&song_id=$song_id")); ! $url_video = $music_root_path . 'modplayer.swf'; ! $mime_type= 'audio/x-' . $song_filetype; //application/x-mplayer2 ! //$row_type = 'mod'; ! $row_type = 'xmod'; ! } ! else if ( ( $song_filetype == 'mp3' ) ) ! { ! $template->assign_block_vars('flv', array()); ! $url_download = mx_append_sid(this_mo_mxurl("music_mode=music_download&song_id=$song_id")); ! $url_video = $music_root_path . 'mediaplayer.swf'; ! $mime_type= 'audio/x-mpeg'; //application/x-mplayer2 ! $row_type = 'flv'; } else if ( ( $song_filetype == 'jpg' ) || ( $song_filetype == 'gif' ) || ( $song_filetype == 'png' ) ) *************** *** 308,311 **** --- 327,331 ---- $url_video = $url_download; $row_type = 'img'; + $song_filename = $thissong['song_filename']; $template->assign_block_vars('img', array( *************** *** 526,544 **** { case 'flv': $url_song = PORTAL_URL. str_replace('./', '/', MUSIC_UPLOAD_PATH) . $thissong['song_filename']; break; case 'mod': - $url_song = PORTAL_URL. str_replace('./', '/', MUSIC_UPLOAD_PATH) . $thissong['song_filename']; - break; - case 's3m': - $url_song = PORTAL_URL. str_replace('./', '/', MUSIC_UPLOAD_PATH) . $thissong['song_filename']; - break; - case 'ult': - $url_song = PORTAL_URL. str_replace('./', '/', MUSIC_UPLOAD_PATH) . $thissong['song_filename']; - break; - case '.xm': $url_song = PORTAL_URL. str_replace('./', '/', MUSIC_UPLOAD_PATH) . $thissong['song_filename']; --- 546,556 ---- { case 'flv': + case 'mp3': $url_song = PORTAL_URL. str_replace('./', '/', MUSIC_UPLOAD_PATH) . $thissong['song_filename']; break; case 'mod': case 's3m': case 'ult': case '.xm': $url_song = PORTAL_URL. str_replace('./', '/', MUSIC_UPLOAD_PATH) . $thissong['song_filename']; Index: music_song.php =================================================================== RCS file: /cvsroot/mxbb/mx_music/music_box/modules/music_song.php,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** music_song.php 7 Sep 2008 18:06:51 -0000 1.3 --- music_song.php 10 Sep 2008 13:55:49 -0000 1.4 *************** *** 233,237 **** { case 'mp3': ! header('Content-type: audio/mp3'); break; case 'wav': --- 233,237 ---- { case 'mp3': ! header('Content-type: audio/x-mpeg'); break; case 'wav': |