PHP Classes

File: x3.php

Recommend this page to a friend!
  Classes of Jonathan Discipulo   EBM2BMP Class   x3.php   Download  
File: x3.php
Role: Example script
Content type: text/plain
Description: Sample script
Class: EBM2BMP Class
Convert emblem images in EBM to BMP format
Author: By
Last change:
Date: 17 years ago
Size: 634 bytes
 

Contents

Class file image Download
<?php

// get variables from query string
parse_str($_SERVER['QUERY_STRING'], $query);

// edit this path pointing to the path where the RO guild emblems were saved
$path = '.';

// includes the EBM2BMP class
include('class.ebm2bmp.php');

// create an instance of EBM2BMP class
$emblem = new EBM2BMP($path);

// convert the EBM file to BMP string
$emblem->convertFile($query['ebm']);

$emblem->replaceColor('FF00FF', 'FFFFFF'); // replaces magenta (FF00FF) to white (FFFFFF)

echo "These are the contents of 'ok.ebm' converted to BMP: <br />";

// display BMP info in an array form
$emblem->showArray();

?>