PHP Classes

File: README.md

Recommend this page to a friend!
  Classes of Juan Chaves   Save and Convert Images   README.md   Download  
File: README.md
Role: Documentation
Content type: text/markdown
Description: Documentation
Class: Save and Convert Images
Retrieve remote images and convert formats
Author: By
Last change: Add format
Add help Readme
Date: 6 years ago
Size: 614 bytes
 

Contents

Class file image Download

Save-And-Convert-Img-PHP

Is a class to save remote images, and change the type of image. Download and convert at the same time a remote file, convert: <pre> PNG to JPG PNG to GIF GIF to JPG GIF to PNG JPG to GIF JPG to PNG

Example:

$load= new SaveAndConvertImg(); //path to save the image. do not put the last slash $load->patch = './img'; //copy image source path $load->url = 'https://www.google.es/images/branding/googlelogo/1x/googlelogo_color_272x92dp.png'; //name of the copy $load->name = 'logo_google'; //type of image to convert - jpg gif png $load->convert = 'jpg'; echo $load->ReturnImage(); </pre>