PHP Classes

File: sample.php

Recommend this page to a friend!
  Classes of Shiegege   Resize and thumbnail picture   sample.php   Download  
File: sample.php
Role: Example script
Content type: text/plain
Description: Simple Sample
Class: Resize and thumbnail picture
Create thumbnail of a picture on the fly
Author: By
Last change: add url
Date: 20 years ago
Size: 430 bytes
 

Contents

Class file image Download
<?
// see online : http://kentung.f2o.org/scripts/thumbnail/sample.php
include_once("resize.php");
$thumb=new thumbnail("/www/shiegege.jpg"); // prepare to generate "shiegege.jpg" in directory "/www"
$thumb->size_width(100); // set width for thumbnail with 100 pixels
$thumb->show(); // show my thumbnail
$thumb->save("/www/thumb/huhu.jpg"); // save my thumbnail to file "huhu.jpg" in directory "/www/thumb
?>