File: imagesample.php

Recommend this page to a friend!
  Classes of Senk Jozsef  >  Image  >  imagesample.php  >  Download  
File: imagesample.php
Role: Example script
Content type: text/plain
Description: How to use my image class
Class: Image
Manage and resize uploaded image files
Author: By
Last change: Bug fixed.
Date: 15 years ago
Size: 1,771 bytes



Class file image Download
include_once "image.php";
    if (
$HTTP_POST_FILES['imagefile']) {
$image=new Image("./",$HTTP_POST_FILES['imagefile']);
        if (
$image->FType!=null) {
'Unsupported file format...';
    else {
    if (
            <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
            <title>Image class sample</title>
            <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
            <link href="../hun/css/style.css" rel="stylesheet" type="text/css">
            <form name="ImageUpForm" id="ImageUpForm" enctype="multipart/form-data" action="imagesample.php" method="post">
            <table width="380" border="0" align="center" cellpadding="0" cellspacing="6" class="border">
              <tr align="center">
                <td colspan="2" class="cim">Image upload</td>
                <td class="szoveg">Image file </td>
                    <input name="imagefile" type="file" class="input" size="40">
                    <input type="hidden" name="MAX_FILE_SIZE" value="1073741824">
              <tr align="center">
                <td colspan="2"><input name="Submit" type="submit" class="gomb" value="Upload"></td>

For more information send a message to info at phpclasses dot org.