you should have script, call it image.php or something like that, the
only thing that should be in that script is this:
<?php
$link = mysql_connect("localhost", "root", "");
if ($link){
        header("Content-type: image/png");
        $im = imagecreatefrompng("images/map/map-15x9.png");
        imagepng($im); //,"images/".session_id().".png"
        imagedestroy($im);
        mysql_close($link);
}
else{
//probably want to have another way to handle this error
        echo("Not connected.");
}
?>


no html tags in there, no whitespace.

to see the image you could call the page like this
http://www.yourdomain.whatever/image.php . you could call it in a
iumage tag like this 

<img src="http://www.yourdomain.whatever/image.php"; />

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to