Changeset 286
- Timestamp:
- Jan 17, 2004, 11:38:04 PM (21 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/release-1_3/category.php
r279 r286 24 24 include_once( './include/init.inc.php' ); 25 25 //---------------------------------------------------------------------- logout 26 if ( isset( $_GET['act'] ) && $_GET['act'] == 'logout' && isset( $_COOKIE['id'] ) ) 26 if ( isset( $_GET['act'] ) 27 and $_GET['act'] == 'logout' 28 and isset( $_COOKIE['id'] ) ) 27 29 { 28 30 // cookie deletion if exists … … 35 37 } 36 38 //-------------------------------------------------- access authorization check 37 if ( isset( $_GET['cat'] )) 38 check_cat_id( $_GET['cat'] ); 39 if ( isset( $_GET['cat'] ) ) check_cat_id( $_GET['cat'] ); 39 40 check_login_authorization(); 40 if ( isset( $page['cat'] ) &&is_numeric( $page['cat'] ) )41 if ( isset( $page['cat'] ) and is_numeric( $page['cat'] ) ) 41 42 { 42 43 check_restrictions( $page['cat'] ); … … 78 79 // The $page['expand'] equals 'all' and 79 80 // $page['tab_expand'] contains all the authorized cat ids 80 if ( $user['expand'] || (isset($_GET['expand']) && $_GET['expand'] == 'all' )) 81 if ( $user['expand'] 82 or ( isset( $_GET['expand'] ) and $_GET['expand'] == 'all' ) ) 81 83 { 82 84 $page['tab_expand'] = array(); … … 87 89 // We have to find the right $page['start'] that show the num picture 88 90 // in this category 89 if ( isset($_GET['num']) && is_numeric( $_GET['num'] ) && $_GET['num'] >= 0 ) 91 if ( isset( $_GET['num'] ) 92 and is_numeric( $_GET['num'] ) 93 and $_GET['num'] >= 0 ) 90 94 { 91 95 $page['start'] = floor( $_GET['num'] / $user['nb_image_page'] ); … … 358 362 359 363 $subcats=array(); 360 if (isset ($page['cat'] ))361 $subcats = get_non_empty_subcat_ids( $page['cat']);364 if (isset($page['cat'])) $subcats = get_non_empty_subcat_ids( $page['cat'] ); 365 else $subcats = get_non_empty_subcat_ids( '' ); 362 366 $cell_number = 1; 363 367 $i = 0; … … 463 467 get_cat_display_name( $page['cat_name'], ' - ', 464 468 'font-style:italic;' ) ); 465 466 467 and $conf['upload_available']468 and $page['cat_uploadable'] )469 470 471 472 473 474 469 // upload a picture in the category 470 if ( $page['cat_site_id'] == 1 471 and $conf['upload_available'] 472 and $page['cat_uploadable'] ) 473 { 474 $vtp->addSession( $handle, 'upload' ); 475 $url = './upload.php?cat='.$page['cat'].'&expand='.$page['expand']; 476 $vtp->setVar( $handle, 'upload.url', add_session_id( $url ) ); 477 $vtp->closeSession( $handle, 'upload' ); 478 } 475 479 } 476 480 else
Note: See TracChangeset
for help on using the changeset viewer.