Re: pictures stored in PostgreSQL DB

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Alain Roger wrote:
Hi,

It's amazing that my previous post has raised so much consideration about
the fact to store or not pictures into DB.

It was nice, wasn't it? :-D

However, none of those posts answered to my question... How can i retrieve
and display those pictures to my PHP pages ?

???

How do you plan to store them? bytea, text with base64 encoding/decoding, blobs?

Basically, on my PHP page I have some texts and I would like to extract from
DB the pictures to display.
Therefore, set the header to mine JPEG or GIF does not allow to have text
also.

You have to do it in two seperate steps (which IMHO is good):

1) First build an app to extract an image and show it. You should test it with you're browser and it should just show the image. 2) Build you're PHP page and make references in scr of the <img> tag to the app above (referencing with some ID to the JPG you want.

I think that you will have to send some headers in one so the the browser knows the length of the image, content type, etc. Not really sure, but it won't hurt to check it out.

So please, how can i do to display pictures from DB, when my PHP page also
include texts and other images (from filesystem) ?

In fact i would like to do something like a thumbnail...

That's a differnet, and even more complicated story.

--
 21:50:04 up 2 days,  9:07,  0 users,  load average: 0.92, 0.37, 0.18
---------------------------------------------------------
Lic. Martín Marqués         |   SELECT 'mmarques' ||
Centro de Telemática        |       '@' || 'unl.edu.ar';
Universidad Nacional        |   DBA, Programador,
    del Litoral             |   Administrador
---------------------------------------------------------

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


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux