|
From: FlorinCB <ory...@us...> - 2008-09-09 06:25:03
|
Update of /cvsroot/mxbb/mx_music In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv20992 Modified Files: music.php Log Message: subcategory support fully added Index: music.php =================================================================== RCS file: /cvsroot/mxbb/mx_music/music.php,v retrieving revision 1.18 retrieving revision 1.19 diff -C2 -d -r1.18 -r1.19 *** music.php 7 Sep 2008 18:06:26 -0000 1.18 --- music.php 9 Sep 2008 06:23:57 -0000 1.19 *************** *** 328,335 **** */ ! $cat_id = $_POST['c'] ? $_POST['c'] : ( $_GET['c'] ? $_GET['c'] : 0 ); $cat_where = "cat_parent = $cat_id"; ! if ($cat_id != 0) { $sql = "SELECT cat_id,cat_title --- 328,335 ---- */ ! $cat_id = $mx_request_vars->request('c', MX_TYPE_INT, 0); //$_POST['c'] ? $_POST['c'] : ( $_GET['c'] ? $_GET['c'] : 0 ); $cat_where = "cat_parent = $cat_id"; ! if (!$mx_request_vars->is_empty_request('c')) { $sql = "SELECT cat_id,cat_title *************** *** 664,667 **** --- 664,674 ---- ); } + elseif ($userdata['user_level'] == ADMIN) + { + $template->assign_block_vars('catrow.subcat_link', array( + 'L_SUBCATS' => '<i>' . $lang['Music_sub_categories'] . '</i>', + 'SUBCATS' => $subcats) + ); + } } // ------------------------------------------ *************** *** 699,711 **** } ! $template->assign_vars(array( ! 'U_VIEW_CAT' => mx_append_sid(this_mo_mxurl("music_mode=music_cat&cat_id=". $catrows[$i]['cat_id'])), ! 'CAT_TITLE' => $thiscat['cat_title'], ! 'CAT_VIEWS' => $thiscat['cat_views'], ! 'CAT_DESC' => $thiscat['cat_desc'], ! 'WIDTH' => ( !empty($media_width) ? $media_width : '425' ), ! 'HEIGHT' => ( !empty($media_height) ? $media_height : '350' ), ! 'S_CATROW' => 2) ! ); if(empty($template->xs_version)) --- 706,734 ---- } ! ! if (!$mx_request_vars->is_empty_request('c')) ! { ! $template->assign_vars(array( ! 'U_VIEW_CAT' => mx_append_sid(this_mo_mxurl("music_mode=music_cat&cat_id=". $catrows[$i]['cat_id'])), ! 'CAT_TITLE' => $thiscat['cat_title'], ! 'CAT_VIEWS' => $thiscat['cat_views'], ! 'CAT_DESC' => $thiscat['cat_desc'], ! 'WIDTH' => ( !empty($media_width) ? $media_width : '425' ), ! 'HEIGHT' => ( !empty($media_height) ? $media_height : '350' ), ! 'SWITCH_HAS_CATROW' => true) ! ); ! } ! else ! { ! $template->assign_vars(array( ! 'U_VIEW_CAT' => mx_append_sid(this_mo_mxurl("music_mode=music_cat&cat_id=". $catrows[$i]['cat_id'])), ! 'CAT_TITLE' => $thiscat['cat_title'], ! 'CAT_VIEWS' => $thiscat['cat_views'], ! 'CAT_DESC' => $thiscat['cat_desc'], ! 'WIDTH' => ( !empty($media_width) ? $media_width : '425' ), ! 'HEIGHT' => ( !empty($media_height) ? $media_height : '350' ), ! 'SWITCH_HAS_CATROW' => false) ! ); ! } if(empty($template->xs_version)) |