Current Path : /web/htdocs/www.entinoprofit.org/home/
Upload File :
Current File : /web/htdocs/www.entinoprofit.org/home/email2jpeg.php

<?php
include("include/config.php");


$idclub = $_GET['id'];

$query  = 'SELECT email FROM club_list WHERE id = "'.$idclub.'"';
$risultato = mysql_query($query) or die(mysql_error());
$array = mysql_fetch_array($risultato, MYSQL_BOTH);



			  // header dell'immagine
			  header("Content-type: image/jpg");
			
			  // indirizzo email
			  $string = $array['email'];
			
			  // impostazioni generali
			  $font  = 4;
			  $width  = ImageFontWidth($font) * strlen($string);
			  $height = ImageFontHeight($font);
			
			  // creazione immagine
			  $im = @imagecreatetruecolor ($width,$height);
			
			  //sfondo bianco
			  $bg = imagecolorallocate($im, 255, 255, 255);

				imagefill($im,0,0,$bg);
			  //testo nero
			  $text_color = imagecolorallocate ($im, 0, 0, 0);
			
			  // conversione del testo in immagine
			  imagestring ($im, $font, 0, 0,  $string, $text_color);
			
			  // visualizzazione
			  imagejpeg ($im,NULL,100);
?>