Location: PHPKode > scripts > Fuerte Image Tool > fuerte-image-tool/example.php
// Using of resize class


$new_width = 100;
$new_height = 100;

// new instance of class
$img = new images('image.jpg');

//create image from form
//$img = new images($_FILES['image'], 'upload');

// create image from string
//$img = new images($string, 'string');

// resizing image (constrain proportions)
$img->resize($new_width, $new_height);

// resizing image (use strictly setted params)
//$img->resize($new_height, $new_height, 'strict');

//saving image

// if you want another type of image
//$img->save('image.png', 'png');
//$img->save('image.gif', 'gif');

// clearing the memory

// check error output
$errors = $img->getErrors();
Return current item: Fuerte Image Tool