pg.ddx.io pgsql-php@postgresql.org mailing list archive
help / color / mirror / Atom feedLarge file upload
8+ messages / 4 participants
[nested] [flat]
* Large file upload
@ 2002-12-10 07:58 Kelvin Varst <kelvin@varst.dk>
0 siblings, 1 reply; 8+ messages in thread
From: Kelvin Varst @ 2002-12-10 07:58 UTC (permalink / raw)
To: pgsql-php
Hi,
I'm trying to upload large files via my homepage. I'm using a form:
print "<form enctype=\"multipart/form-data\" action=\"approve_element.php\"
method=\"POST\">";
And with files up to approx 500kb it works. But with larger files, the
browser can't find the page, and if I refresh the page, I get some query
errors. In the php.ini the post_max_size is set to 8M.
Kelvin :-)
^ permalink raw reply [nested|flat] 8+ messages in thread
* Re: Large file upload
@ 2002-12-10 10:30 sharmad@softhome.net
0 siblings, 0 replies; 8+ messages in thread
From: sharmad@softhome.net @ 2002-12-10 10:30 UTC (permalink / raw)
To: pgsql-php
Thanks everyone,
The problem was lying in the hostname not specified which php as usual
wouldn't tell me
pg_connect("host=$rr dbname=$rr user=$rr");
Thanks
Sharmad
Kelvin Varst writes:
>
> Hi,
>
> I'm trying to upload large files via my homepage. I'm using a form:
> print "<form enctype=\"multipart/form-data\" action=\"approve_element.php\"
> method=\"POST\">";
>
> And with files up to approx 500kb it works. But with larger files, the
> browser can't find the page, and if I refresh the page, I get some query
> errors. In the php.ini the post_max_size is set to 8M.
>
> Kelvin :-)
>
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 3: if posting/reading through Usenet, please send an appropriate
> subscribe-nomail command to majordomo@postgresql.org so that your
> message can get through to the mailing list cleanly
Feel free to contact me (flames about my english and the useless of this
driver will be redirected to /dev/null, oh no, it's full...). (Michael
Beck, describing the PC-speaker sound device)
^ permalink raw reply [nested|flat] 8+ messages in thread
* Re: Large file upload
@ 2002-12-10 11:40 Vince Vielhaber <vev@michvhf.com>
parent: Kelvin Varst <kelvin@varst.dk>
0 siblings, 0 replies; 8+ messages in thread
From: Vince Vielhaber @ 2002-12-10 11:40 UTC (permalink / raw)
To: Kelvin Varst <kelvin@varst.dk>; +Cc: pgsql-php
On Tue, 10 Dec 2002, Kelvin Varst wrote:
>
> Hi,
>
> I'm trying to upload large files via my homepage. I'm using a form:
> print "<form enctype=\"multipart/form-data\" action=\"approve_element.php\"
> method=\"POST\">";
>
> And with files up to approx 500kb it works. But with larger files, the
> browser can't find the page, and if I refresh the page, I get some query
> errors. In the php.ini the post_max_size is set to 8M.
If it's taking longer than about 25-30 seconds you could be timing out.
Try putting set_time_limit(0) at the top of the script. If it works you
might want to try replacing the 0 with a reasonable time limit. The time
is in seconds.
Vince.
--
Fast, inexpensive internet service 56k and beyond! http://www.pop4.net/
http://www.meanstreamradio.com http://www.unknown-artists.com
Internet radio: It's not file sharing, it's just radio.
^ permalink raw reply [nested|flat] 8+ messages in thread
* Re: Large file upload
@ 2002-12-10 13:56 jco@cornelius-olsen.dk
0 siblings, 1 reply; 8+ messages in thread
From: jco@cornelius-olsen.dk @ 2002-12-10 13:56 UTC (permalink / raw)
To: Vince Vielhaber <vev@michvhf.com>; +Cc: pgsql-php
If it's taking longer than about 25-30 seconds you could be timing out.
Try putting set_time_limit(0) at the top of the script. If it works you
might want to try replacing the 0 with a reasonable time limit. The time
is in seconds.
Vince.
Are you sure that would work? I may be wrong, but my gues would be that
the "set_time_limit(0)" would not be evaluated until the posted file has
been received and then the php starts executing. I would think that one
has to change a php-setting hard.
/Jørn Cornelius Olsen
^ permalink raw reply [nested|flat] 8+ messages in thread
* Re: Large file upload
@ 2002-12-10 14:16 Vince Vielhaber <vev@michvhf.com>
parent: jco@cornelius-olsen.dk
0 siblings, 0 replies; 8+ messages in thread
From: Vince Vielhaber @ 2002-12-10 14:16 UTC (permalink / raw)
To: jco@cornelius-olsen.dk; +Cc: pgsql-php
On Tue, 10 Dec 2002 jco@cornelius-olsen.dk wrote:
> If it's taking longer than about 25-30 seconds you could be timing out.
> Try putting set_time_limit(0) at the top of the script. If it works you
> might want to try replacing the 0 with a reasonable time limit. The time
> is in seconds.
>
> Vince.
>
> Are you sure that would work? I may be wrong, but my gues would be that
> the "set_time_limit(0)" would not be evaluated until the posted file has
> been received and then the php starts executing. I would think that one
> has to change a php-setting hard.
Not sure if it will or not. I used it recently for a similar problem
but right now I don't recall if it was for an upload or something else.
Vince.
--
Fast, inexpensive internet service 56k and beyond! http://www.pop4.net/
http://www.meanstreamradio.com http://www.unknown-artists.com
Internet radio: It's not file sharing, it's just radio.
^ permalink raw reply [nested|flat] 8+ messages in thread
* Re: Large file upload
@ 2002-12-10 19:03 Kelvin Varst <kelvin@varst.dk>
0 siblings, 1 reply; 8+ messages in thread
From: Kelvin Varst @ 2002-12-10 19:03 UTC (permalink / raw)
To: Vince Vielhaber <vev@michvhf.com>; +Cc: pgsql-php
Hi,
The upload takes more than 30 seconds, but I get the error immediately. I
dont think that the webserver is aware of the page will take longer than 30
seconds to upload and therefore sends an error at the beginning of the
upload.
Kelvin :-)
-----Oprindelig meddelelse-----
Fra: Vince Vielhaber [mailto:vev@michvhf.com]
Sendt: 10. december 2002 12:41
Til: Kelvin Varst
Cc: Postgresql PHP
Emne: Re: [PHP] Large file upload
On Tue, 10 Dec 2002, Kelvin Varst wrote:
>
> Hi,
>
> I'm trying to upload large files via my homepage. I'm using a form:
> print "<form enctype=\"multipart/form-data\"
action=\"approve_element.php\"
> method=\"POST\">";
>
> And with files up to approx 500kb it works. But with larger files, the
> browser can't find the page, and if I refresh the page, I get some query
> errors. In the php.ini the post_max_size is set to 8M.
If it's taking longer than about 25-30 seconds you could be timing out.
Try putting set_time_limit(0) at the top of the script. If it works you
might want to try replacing the 0 with a reasonable time limit. The time
is in seconds.
Vince.
--
Fast, inexpensive internet service 56k and beyond! http://www.pop4.net/
http://www.meanstreamradio.com http://www.unknown-artists.com
Internet radio: It's not file sharing, it's just radio.
^ permalink raw reply [nested|flat] 8+ messages in thread
* Re: Large file upload
@ 2002-12-10 19:29 jco@cornelius-olsen.dk
0 siblings, 0 replies; 8+ messages in thread
From: jco@cornelius-olsen.dk @ 2002-12-10 19:29 UTC (permalink / raw)
To: Kelvin Varst <kelvin@varst.dk>; +Cc: pgsql-php
At www.php.net someone writes:
"When uploading very large files (greater than the default 8M) I found
that I had alter not only the "max_file_size" input and the php.ini
max_file_size limit, but ALSO the "post_max_size" variable in the php.ini
file.
Because I was submitting the file via a POST request, it would hit this
limit and deny the upload."
If that still doesn't help you might consider telling us what error
messages you are getting.
Regards
/Jørn
"Kelvin Varst" <kelvin@varst.dk>
Sent by: pgsql-php-owner@postgresql.org
10-12-2002 20:03
To: "Vince Vielhaber" <vev@michvhf.com>
cc: "Postgresql PHP" <pgsql-php@postgresql.org>
Subject: Re: [PHP] Large file upload
Hi,
The upload takes more than 30 seconds, but I get the error immediately. I
dont think that the webserver is aware of the page will take longer than
30
seconds to upload and therefore sends an error at the beginning of the
upload.
Kelvin :-)
-----Oprindelig meddelelse-----
Fra: Vince Vielhaber [mailto:vev@michvhf.com]
Sendt: 10. december 2002 12:41
Til: Kelvin Varst
Cc: Postgresql PHP
Emne: Re: [PHP] Large file upload
On Tue, 10 Dec 2002, Kelvin Varst wrote:
>
> Hi,
>
> I'm trying to upload large files via my homepage. I'm using a form:
> print "<form enctype=\"multipart/form-data\"
action=\"approve_element.php\"
> method=\"POST\">";
>
> And with files up to approx 500kb it works. But with larger files, the
> browser can't find the page, and if I refresh the page, I get some query
> errors. In the php.ini the post_max_size is set to 8M.
If it's taking longer than about 25-30 seconds you could be timing out.
Try putting set_time_limit(0) at the top of the script. If it works you
might want to try replacing the 0 with a reasonable time limit. The time
is in seconds.
Vince.
--
Fast, inexpensive internet service 56k and beyond! http://www.pop4.net/
http://www.meanstreamradio.com http://www.unknown-artists.com
Internet radio: It's not file sharing, it's just radio.
---------------------------(end of broadcast)---------------------------
TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org
^ permalink raw reply [nested|flat] 8+ messages in thread
* Re: Large file upload
@ 2002-12-10 20:20 Vince Vielhaber <vev@michvhf.com>
parent: Kelvin Varst <kelvin@varst.dk>
0 siblings, 0 replies; 8+ messages in thread
From: Vince Vielhaber @ 2002-12-10 20:20 UTC (permalink / raw)
To: Kelvin Varst <kelvin@varst.dk>; +Cc: pgsql-php
On Tue, 10 Dec 2002, Kelvin Varst wrote:
>
> Hi,
>
> The upload takes more than 30 seconds, but I get the error immediately. I
> dont think that the webserver is aware of the page will take longer than 30
> seconds to upload and therefore sends an error at the beginning of the
> upload.
I seem to have trimmed the message out. What exactly does the message
say and what server and browser are you using?
>
> Kelvin :-)
>
> -----Oprindelig meddelelse-----
> Fra: Vince Vielhaber [mailto:vev@michvhf.com]
> Sendt: 10. december 2002 12:41
> Til: Kelvin Varst
> Cc: Postgresql PHP
> Emne: Re: [PHP] Large file upload
>
>
>
> On Tue, 10 Dec 2002, Kelvin Varst wrote:
>
> >
> > Hi,
> >
> > I'm trying to upload large files via my homepage. I'm using a form:
> > print "<form enctype=\"multipart/form-data\"
> action=\"approve_element.php\"
> > method=\"POST\">";
> >
> > And with files up to approx 500kb it works. But with larger files, the
> > browser can't find the page, and if I refresh the page, I get some query
> > errors. In the php.ini the post_max_size is set to 8M.
>
> If it's taking longer than about 25-30 seconds you could be timing out.
> Try putting set_time_limit(0) at the top of the script. If it works you
> might want to try replacing the 0 with a reasonable time limit. The time
> is in seconds.
>
> Vince.
> --
> Fast, inexpensive internet service 56k and beyond! http://www.pop4.net/
> http://www.meanstreamradio.com http://www.unknown-artists.com
> Internet radio: It's not file sharing, it's just radio.
>
>
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org
>
Vince.
--
Fast, inexpensive internet service 56k and beyond! http://www.pop4.net/
http://www.meanstreamradio.com http://www.unknown-artists.com
Internet radio: It's not file sharing, it's just radio.
^ permalink raw reply [nested|flat] 8+ messages in thread
end of thread, other threads:[~2002-12-10 20:20 UTC | newest]
Thread overview: 8+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2002-12-10 07:58 Large file upload Kelvin Varst <kelvin@varst.dk>
2002-12-10 11:40 ` Vince Vielhaber <vev@michvhf.com>
2002-12-10 10:30 Re: Large file upload sharmad@softhome.net
2002-12-10 13:56 Re: Large file upload jco@cornelius-olsen.dk
2002-12-10 14:16 ` Vince Vielhaber <vev@michvhf.com>
2002-12-10 19:03 Re: Large file upload Kelvin Varst <kelvin@varst.dk>
2002-12-10 20:20 ` Vince Vielhaber <vev@michvhf.com>
2002-12-10 19:29 Re: Large file upload jco@cornelius-olsen.dk
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox