+ if (strpos($size, 'x') !== FALSE) {
+ list ($width, $height) = explode('x', $size);
+ if (empty($height)) {
+ $height = $width * 4;
+ }
+ }
+ else {
+ $height = $size;
+ }
+ if (empty($width)) {
+ $width = $height * 4;
+ }
+ $target = "thumb/$size/$source";