Greetings,
I’m new in scriptcase and I need to resize images for a form before them upload to the server, i’m trying to use the “wideimage” (http://wideimage.sourceforge.net/documentation/manipulating-images/) library but it dont work i spected.
Here is the code i use on the “onBeforeInsert” event.
Image Field name: ImageName
sc_include_library(“prj”, “wideimage”, “WideImage.php”, true, true);
$image = WideImage::load({ImageName});
$resized = $image->resize(1280, 1280);
$img_resized = $resized->asString(‘jpg’, 80);
{ImageName} = $img_resized;
If are other solution to this problem please share me!