Login   Register  
PHP Classes
elePHPant
Icontem

File: example-13.php

Recommend this page to a friend!
Stumble It! Stumble It! Bookmark in del.icio.us Bookmark in del.icio.us
  Classes of Krzysztof Kardasz  >  Nweb Image  >  example-13.php  >  Download  
File: example-13.php
Role: Example script
Content type: text/plain
Description: Example
Class: Nweb Image
Perform several image manipulation operations
Author: By
Last change:
Date: 2007-10-14 22:00
Size: 784 bytes
 

Contents

Class file image Download
<?php
/**
 * Nweb Extension Script
 *
 * Example
 *
 * @category   Nweb
 * @package    Nweb_Scripts
 * @author     Krzysztof Kardasz
 * @copyright  Copyright (c) euo.pl
 */


    
include 'lib/Image.php';
    include 
'lib/ImageException.php';


try {

    
# Otwieramy wszystkie zdjecia

    
$obj_1 = new Image('photos/image-01.jpg');
    
$obj_1->open();

    
$obj_2 = new Image('photos/watermark2.gif');
    
$obj_2->open();


    
# Komponujemy zdjecia
    
$obj_1->Compose ($obj_2Image::RIGHT Image::BOTTOM100);

    
# Wyświetlenie zdjęcia
    
$obj_1->Display();

    
# Wyczyszczenie pamięci przydzielonej dla zdjęcia
    
$obj_1->ImageClear();
    
$obj_2->ImageClear();

}
catch (
ImageException $e)
{
    echo 
$e->Message();
}


?>