Login   Register  
PHP Classes
elePHPant
Icontem

File: examples/savingCash/index.php

Recommend this page to a friend!
Stumble It! Stumble It! Bookmark in del.icio.us Bookmark in del.icio.us
  Classes of hyyan  >  Tulip Image Processor  >  examples/savingCash/index.php  >  Download  
File: examples/savingCash/index.php
Role: Example script
Content type: text/plain
Description: index
Class: Tulip Image Processor
Apply different types of effects to images
Author: By
Last change:
Date: 2 years ago
Size: 660 bytes
 

Contents

Class file image Download
<?php
/**
 * Require The tuliIP class
 */
require_once '../../tulipIP/tulipIP.class.php';

/**
 * Load The Image From Source File
 */
$path "../../src.jpg";
$image tulipIP::loadImage($path);

/*
 * save compressed gd2 casg file so we can restore it after
 * page refresh or sudden shutdown or ....
 */

$dest "./";
tulipIP::saveGD($dest$image"cash-file");

// destroy the resource
imagedestroy($image);

/**
 * Load The Casg File From dest
 */

$image=tulipIP::loadGD($dest"cash-file");

// save the result
header('Content-type:' TIP_PNG);
tulipIP::saveImage(null$image);
tulipIP::saveImage($dest$imageTIP_JPG"Loaded From Cash File");
?>