Saving

The save() method requires at least one parameter, the filename as which the scaled image is to be saved as. With only one parameter, the type of the new image is the same as the original type.

File extensions are not appended if left out.

The second parameter can be the extension of the file type you want to save the image as, for example png or jpg.

In case of an error - for example if the driver does not support to write the file type - a PEAR_Error object is returned.

Instead of saving, you can directly put out the image to the browser using display().

    Поддержать сайт на родительском проекте КГБ