upload a image file and save into the table

Поиск
Список
Период
Сортировка
Искать

upload a image file and save into the table

От:
"Zhidian Du" <duzhidian@hotmail.com>
Дата:
Hello:


I want to let users  upload a image file (jpg or gif or any binary file) 
from browser and save these files into one column of a table, how can i 
implement it ?

Thanks in advance.

Zhidian Du


_________________________________________________________________
Chat with friends online, try MSN Messenger: http://messenger.msn.com

Re: upload a image file and save into the table

От:
"Christopher Kings-Lynne" <chriskl@familyhealth.com.au>
Дата:
> I want to let users  upload a image file (jpg or gif or any binary file)
> from browser and save these files into one column of a table, how can i
> implement it ?

Use the 'bytea' column type.  You must properly escape the binary data
before inserting it tho. There are functions in PHP's postgres module to do
this.

Chris

Re: upload a image file and save into the table

От:
Joe Conway <mail@joeconway.com>
Дата:
Zhidian Du wrote:
> I want to let users  upload a image file (jpg or gif or any binary file) 
> from browser and save these files into one column of a table, how can i 
> implement it ?
> 

Please search the archives. There have been multiple discussions about this in 
the past. Here's a link to one thread:

http://archives.postgresql.org/pgsql-general/2002-02/msg01140.php

Joe

FAQ