File: example/example.php

Recommend this page to a friend!
  Classes of Lewis Ferguson  >  ISC  >  example/example.php  >  Download  
File: example/example.php
Role: Example script
Content type: text/plain
Description: Example script
Class: ISC
Display a resized image in a HTML page
Author: By
Last change: Changed script layout
Date: 11 years ago
Size: 864 bytes
 

Contents

Class file image Download
<?PHP
include("../class/ISC.class.php");
$img = new image();
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
</head>

<body>
Original: <br />
<img src="turing_test.png" /><br />
50px Width:<br />
<?PHP
$img
->getRatio("turing_test.png", "50", TRUE);
$img->printHTML();
?>
<br />
100px Height:<br />
<?PHP
$img
->getRatio("turing_test.png", "100", FALSE);
$img->printHTML(); ?>
<br />
500px Width:<br />
<?PHP
$img
->getRatio("turing_test.png", "500", TRUE);
$img->printHTML(); ?>
<br />
1000px Height:<br />
<?PHP
$img
->getRatio("turing_test.png", "1000", FALSE);
$img->printHTML(); ?>
</body>
</html>


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