Changeset 13052 for trunk/admin/picture_coi.php
- Timestamp:
- Feb 7, 2012, 10:25:20 PM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/admin/picture_coi.php
r13038 r13052 58 58 if (isset($_POST['submit'])) 59 59 { 60 delete_element_derivatives($row); 60 foreach(ImageStdParams::get_defined_type_map() as $params) 61 { 62 if ($params->sizing->max_crop != 0) 63 { 64 delete_element_derivatives($row, $params->type); 65 } 66 } 67 delete_element_derivatives($row, IMG_CUSTOM); 68 $uid = '&b='.time(); 69 $conf['question_mark_in_urls'] = $conf['php_extension_in_urls'] = true; 70 if ($conf['derivative_url_style']==1) 71 { 72 $conf['derivative_url_style']=0; //auto 73 } 74 } 75 else 76 { 77 $uid = ''; 61 78 } 62 79 … … 77 94 } 78 95 79 if (isset($_POST['submit']))96 foreach(ImageStdParams::get_defined_type_map() as $params) 80 97 { 81 $uid = '&b='.time(); 82 $conf['question_mark_in_urls'] = $conf['php_extension_in_urls'] = true; 83 $conf['derivative_url_style']=2; //script 84 $tpl_var['U_SQUARE'] = DerivativeImage::url(IMG_SQUARE, $row).$uid; 85 $tpl_var['U_THUMB'] = DerivativeImage::url(IMG_THUMB, $row).$uid; 98 if ($params->sizing->max_crop != 0) 99 { 100 $derivative = new DerivativeImage($params, new SrcImage($row) ); 101 $template->append( 'cropped_derivatives', array( 102 'U_IMG' => $derivative->get_url().$uid, 103 'HTM_SIZE' => $derivative->get_size_htm(), 104 ) ); 105 } 86 106 } 87 else 88 { 89 $tpl_var['U_SQUARE'] = DerivativeImage::url(IMG_SQUARE, $row); 90 $tpl_var['U_THUMB'] = DerivativeImage::url(IMG_THUMB, $row); 91 } 107 92 108 93 109 $template->assign($tpl_var);
Note: See TracChangeset
for help on using the changeset viewer.