Php scaling image. How to use: set the width and height, and scale proportionally? Phpinclude(simpleimage.php?##imagenewsimpleimage(%%%%image-load(picture.jpg); $ image-resize (250,400); $ image-save (picture2. usage:
Set width and height, and scale proportionally
Include ('simpleimage. php ');
$ Image = new SimpleImage ();
$ Image-> load('picture.jpg ');
$ Image-> resize( 250,400 );
$ Image-> save('picture2.jpg ');?> Set width and proportional scaling Include ('simpleimage. php ');
$ Image = new SimpleImage ();
$ Image-> load('picture.jpg ');
$ Image-> resizeToWidth (250 );
$ Image-> save('picture2.jpg ');?> Set height, proportional scaling Include ('simpleimage. php ');
$ Image = new SimpleImage ();
$ Image-> load('picture.jpg ');
$ Image-> resizeToHeight (500 );
$ Image-> save('picture2.jpg ');
$ Image-> resizeToHeight (200 );
$ Image-> save('picture3.jpg ');?> Scale to 50% in proportion Include ('simpleimage. php ');
$ Image = new SimpleImage ();
$ Image-> load('picture.jpg ');
$ Image-> scale (50 );
$ Image-> save('picture2.jpg ');?> Scale and output directly to the screen Header ('content-Type: image/jpeg ');
Include ('simpleimage. php ');
$ Image = new SimpleImage ();
$ Image-> load('picture.jpg ');
$ Image-> resizeToWidth (150 );
$ Image-> output ();?>
What is the proportional scaling between the width and height of a shard? Php include (SimpleImage. php); $ image = new SimpleImage (); your image-load(picture.jpg); $ image-resize (250,400); $ image-save (picture2 ....