Changeset 12908 for trunk/index.php
- Timestamp:
- Jan 17, 2012, 7:09:32 AM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/index.php
r12553 r12908 3 3 // | Piwigo - a PHP based photo gallery | 4 4 // +-----------------------------------------------------------------------+ 5 // | Copyright(C) 2008-201 1Piwigo Team http://piwigo.org |5 // | Copyright(C) 2008-2012 Piwigo Team http://piwigo.org | 6 6 // | Copyright(C) 2003-2008 PhpWebGallery Team http://phpwebgallery.net | 7 7 // | Copyright(C) 2002-2003 Pierrick LE GALL http://le-gall.net/pierrick | … … 61 61 ); 62 62 } 63 if (isset($_GET['display'])) 64 { 65 $page['meta_robots']['noindex']=1; 66 if (array_key_exists($_GET['display'], ImageStdParams::get_defined_type_map())) 67 { 68 pwg_set_session_var('index_deriv', $_GET['display']); 69 } 70 } 63 71 //-------------------------------------------------------------- initialization 64 72 … … 253 261 } 254 262 263 if ( count($page['items']) > 0 ) 264 { 265 $url = add_url_params( 266 duplicate_index_url(), 267 array('display' => '') 268 ); 269 $selected_type = pwg_get_session_var('index_deriv', IMG_THUMB); 270 $type_map = ImageStdParams::get_defined_type_map(); 271 unset($type_map[IMG_XXLARGE], $type_map[IMG_XLARGE]); 272 foreach($type_map as $params) 273 { 274 $template->append( 275 'image_derivatives', 276 array( 277 'DISPLAY' => l10n($params->type), 278 'URL' => $url.$params->type, 279 'SELECTED' => ($params->type == $selected_type ? true:false), 280 ) 281 ); 282 } 283 } 284 255 285 // category comment 256 286 if ($page['start']==0 and !isset($page['chronology_field']) and !empty($page['comment']) )
Note: See TracChangeset
for help on using the changeset viewer.