hi all
I have this script that i found and modified slightly it appears to use some code i am not famalier with so trouble shooting has turned into a night mare but here is what i have
this part is on my page where i want the image displayed
[HTML]
<img src="imagedisp. php?title=asdf" >
[/HTML]
here is the imagedisp.php page
[PHP]
$result = "SELECT imgdata, type FROM pix WHERE title='$title'" ;
$Show = mysql ( $hDB, $hSQL );
$rows = mysql_num_rows( $hShow);
if($rows<1){
// no image matches this query
}
else{
// at least one image has this title
$getPhoto = mysql_fetch_obj ect($Show);
// we need to determine the mime type
$Type = $getPhoto->type;
// and send the correct header to the browser
Header("Content-type: $Type");
// now send the image
$Body = $getPhoto->body;
echo $Body;
flush();
}
[/PHP]
thanks for any guidence
eric
I have this script that i found and modified slightly it appears to use some code i am not famalier with so trouble shooting has turned into a night mare but here is what i have
this part is on my page where i want the image displayed
[HTML]
<img src="imagedisp. php?title=asdf" >
[/HTML]
here is the imagedisp.php page
[PHP]
$result = "SELECT imgdata, type FROM pix WHERE title='$title'" ;
$Show = mysql ( $hDB, $hSQL );
$rows = mysql_num_rows( $hShow);
if($rows<1){
// no image matches this query
}
else{
// at least one image has this title
$getPhoto = mysql_fetch_obj ect($Show);
// we need to determine the mime type
$Type = $getPhoto->type;
// and send the correct header to the browser
Header("Content-type: $Type");
// now send the image
$Body = $getPhoto->body;
echo $Body;
flush();
}
[/PHP]
thanks for any guidence
eric
Comment