note 66321 added to faq
| From: | mannedinesh at yahoo dot com | Date: | Fri, 19 May 2006 05:40:31 +0000 |
| Subject: | note 66321 added to faq | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-111642@lists.php.net to get a copy of this message | ||
sir,
I am displaying my image from my data base,
my code is as follows.
@MYSQL_CONNECT("localhost","root","");
@mysql_select_db("shopping");
$query = "select bin_data,filetype from binary_data where id=$id";
$result = @MYSQL_QUERY($query);
$data = @MYSQL_RESULT($result,0,"bin_data");
$type = @MYSQL_RESULT($result,0,"filetype");
Header( "Content-type: $type");
echo $data;
echo $type;
it gives binary information of the image only.
it dont get the real image in browser.
if any one get answer please reply to me
----
Server IP: 203.199.124.111
Probable Submitter: 210.18.146.227 (proxied: 210.18.146.227)
----
X-Spam-Status: No, hits=3.1 required=5.0 tests=DATE_MISSING,FROM_NO_LOWER
autolearn=no version=2.64
----
Manual Page -- http://www.php.net/manual/en/faq.php
Edit -- http://master.php.net/note/edit/66321
Del: integrated -- http://master.php.net/note/delete/66321/integrated
Del: useless -- http://master.php.net/note/delete/66321/useless
Del: bad code -- http://master.php.net/note/delete/66321/bad+code
Del: spam -- http://master.php.net/note/delete/66321/spam
Del: non-english -- http://master.php.net/note/delete/66321/non-english
Del: in docs -- http://master.php.net/note/delete/66321/in+docs
Del: other reasons-- http://master.php.net/note/delete/66321
Reject -- http://master.php.net/note/reject/66321
Search -- http://master.php.net/manage/user-notes.php