PHP InterBase Multiple BLOBs display
| From: | Marian Vigenin | Date: | Sat, 16 Feb 2002 02:54:15 +0000 |
| Subject: | PHP InterBase Multiple BLOBs display | ||
| Groups: | php.db | ||
| Request: | Send a blank email to php-db+get-16991@lists.php.net to get a copy of this message | ||
Hi, I have read several posting on How to display a graphical BLOB but all
of them show how to display only one image. I need to display all the images
found in the query including some descriptions for that images.
I tried the following but of course only one image appeared.
<?PHP
header("Content-type: image/jpeg");
$table1 = 'myBLOB';
$db_user = 'SYSDBA';
$db_pass = 'masterkey';
$host = 'd:/Program Files/Borland/InterBase/bin/Test.gdb';
$query1 = "SELECT * FROM $table1 WHERE ID<100 ORDER BY ID";
$query2 = "INSERT INTO $table1 (ID,Pic) VALUES (4,?)";
$connHndl = ibase_connect($host,$db_user,$db_pass) or die ("Cannot
comunicate with the DataBase");
$set = ibase_query("SELECT * from $table1 where ID<100");
while($row = ibase_fetch_row($set)){
ibase_blob_echo($row[1]);
}
ibase_close($connHndl);
?>
A little source would be appreciated.