- 01
- 02
- 03
- 04
- 05
- 06
- 07
- 08
- 09
- 10
- 11
- 12
- 13
- 14
- 15
- 16
- 17
- 18
- 19
- 20
- 21
- 22
- 23
- 24
- 25
- 26
- 27
- 28
- 29
- 30
// There is an error while creating thumbnail in m or in s or in l
if ($creatingSError || $creatingMError || $creatingLError) {
// if all or two errors appear, we only display the last error message
// because the errors in this case is the same
if ($errorMsgS != '') {
$creatingError = $errorMsgS;
}
if ($errorMsgM != '') {
$creatingError = $errorMsgM;
}
if ($errorMsgL != '') {
$creatingError = $errorMsgL;
} // because the errors in this case is the same
$returnFrontMessage = $creatingError;
} else if ($errorMsgS == '' && $errorMsgM == '' && $errorMsgL == '') {
$returnFrontMessage = 'Success';
} else if ($errorMsgS == '' && $errorMsgM == '' && $errorMsgL == 'ThumbnailExists') {
$returnFrontMessage = 'Success';
} else if ($errorMsgS == '' && $errorMsgM == 'ThumbnailExists' && $errorMsgL == 'ThumbnailExists') {
$returnFrontMessage = 'Success';
} else if ($errorMsgS == '' && $errorMsgM == 'ThumbnailExists' && $errorMsgL == '') {
$returnFrontMessage = 'Success';
} else if ($errorMsgS == 'ThumbnailExists' && $errorMsgM == 'ThumbnailExists' && $errorMsgL == '') {
$returnFrontMessage = 'Success';
} else if ($errorMsgS == 'ThumbnailExists' && $errorMsgM == '' && $errorMsgL == '') {
$returnFrontMessage = 'Success';
} else if ($errorMsgS == 'ThumbnailExists' && $errorMsgM == '' && $errorMsgL == 'ThumbnailExists') {
$returnFrontMessage = 'Success';
}
Модуль phocagallery для joomla. Кусок кода в функции генереции превьюшек 3х разных размеров.