// ImageType is now applied to a them

This commit is contained in:
rGaillard
2011-12-22 21:48:40 +00:00
parent b18783b7de
commit 916fb7de9d
19 changed files with 1714 additions and 1717 deletions
+3 -2
View File
@@ -74,10 +74,11 @@ class AdminScenesControllerCore extends AdminController
$images_types = ImageType::getImagesTypes('scenes');
foreach ($images_types as $k => $image_type)
{
$theme = (Shop::isFeatureActive() ? '-'.$image_type['id_theme'] : '');
if ($image_type['name'] == 'large_scene' && isset($_FILES['image']))
imageResize(
$_FILES['image']['tmp_name'],
_PS_SCENE_IMG_DIR_.$obj->id.'-'.stripslashes($image_type['name']).'.jpg',
_PS_SCENE_IMG_DIR_.$obj->id.'-'.stripslashes($image_type['name']).$theme.'.jpg',
(int)$image_type['width'],
(int)$image_type['height']
);
@@ -89,7 +90,7 @@ class AdminScenesControllerCore extends AdminController
$tmp_name = $_FILES['image']['tmp_name'];
imageResize(
$tmp_name,
_PS_SCENE_THUMB_IMG_DIR_.$obj->id.'-'.stripslashes($image_type['name']).'.jpg',
_PS_SCENE_THUMB_IMG_DIR_.$obj->id.'-'.stripslashes($image_type['name']).$theme.'.jpg',
(int)$image_type['width'],
(int)$image_type['height']
);