Re: Showing an Image
| From: | mike cullerton | Date: | Mon, 02 Jul 2001 15:30:12 +0000 |
| Subject: | Re: Showing an Image | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-55846@lists.php.net to get a copy of this message | ||
how about something like,
$result = @mysql_query($sql);
$data = @mysql_result($result, 0, "PICTURE");
$type = @mysql_result($result, 0, "FILETYPE");
$comment = @mysql_result($result, 0, "COMMENT");
Header("Content-type: $type");
echo $data . "<br>" . $comment;
or, instead of using Header, create a page and inside it put
printf("%s<br>%s",$image,$comment)
mike
on 7/2/01 1:39 AM, kachaloo at kachaloo@hotmail.com wrote:
> HI,
> I want to show an image from a database but to do that I am using :
> $result = @mysql_query($sql);
> $data = @mysql_result($result, 0, "PICTURE");
> $type = @mysql_result($result, 0, "FILETYPE");
> Header("Content-type: $type");
> echo $data;
>
>
> but after this I also want to show some text info. How can I do this ? I
> will have to use something else besides header. Please Help.
> Thanks,
> Vishal
>
>
-- mike cullerton michaelc@cullerton.com