nihilism machine wrote:
any ideas why this does not work?
1) the field in the form might not be 'upload1'.
2) the file is too big to upload (> max_upload_size)
3) the /tmp folder might not be writable or full
4) the folder you're trying to write into is not writable (or the drive
is full)
5)
On Jan 22, 2008 8:01 PM, nihilism machine <[EMAIL PROTECTED]> wrote:
> any ideas why this does not work?
>
>
> class upload {
>
> function upload() {
> upload::uploader();
> }
>
> function uploader() {
> $FileName = basename($_FILES['upload1']
On Jan 22, 2008, at 5:01 PM, nihilism machine
<[EMAIL PROTECTED]> wrote:
any ideas why this does not work?
class upload {
function upload() {
upload::uploader();
}
function uploader() {
$FileName = basename($_FILES['upload1']['name']);
if (move_uploaded_file($
Le 2007-05-08 à 16:50, Richard Davey a écrit :
By how much is the difference? Are we talking a few bytes, a few
megabytes, what?
A 116Kb file produce a 68Kb file on the server. And a 152Kb file
produce a 48Kb file on the server...
If you then download the file again, is it corrupted, o
On Tue, May 8, 2007 2:12 pm, Eric Trahan wrote:
> $error = $_FILES['uneimage']['error'];
>
> That doesn't seem work in PHP 4.1.2... I try it but $error is empty.
>
>
> And the function move_uploaded_file($_FILES['uneimage']['tmp_name'],
> $target_path) returns TRUE, so the upload work (in a way !)
Eric Trahan wrote:
$error = $_FILES['uneimage']['error'];
That doesn't seem work in PHP 4.1.2... I try it but $error is empty.
It just means there wasn't an error.
And the function move_uploaded_file($_FILES['uneimage']['tmp_name'],
$target_path) returns TRUE, so the upload work (in a way
$error = $_FILES['uneimage']['error'];
That doesn't seem work in PHP 4.1.2... I try it but $error is empty.
And the function move_uploaded_file($_FILES['uneimage']['tmp_name'],
$target_path) returns TRUE, so the upload work (in a way !).
The problem is the file that is upload doesn't match
On Tue, May 8, 2007 11:30 am, Eric Trahan wrote:
> The upload work. The user file is uploaded to my destination folder
> (page5/) but the file is unreadable and the file size is smaller than
> the original file size.
> $tmp_name = $_FILES['uneimage']['tmp_name'];
> $type = $_FILES['uneimage']['t
On Monday 28 July 2003 21:47, Rosen wrote:
> I have some problem with uploading files on server with PHP.
> The upload is ok, but I must set directory permissions with FULL Access -
> but this is not a good idea :((
> Have someone idea how I can do this with no setting permissions to full
> acess
Use move_uploaded_file() instead of copy()
fr r wrote:
i'm trying to do a very simple thing:
upload image but it keep giving me this error although i gave permession on folder:
Warning: open_basedir restriction in effect. File is in wrong directory in /var/www/vhosts/negoumelshasha.com/httpdocs/t
[snip]
i'm trying to do a very simple thing:
upload image but it keep giving me this error although i gave permession
on folder:
Warning: open_basedir restriction in effect. File is in wrong directory
in /var/www/vhosts/negoumelshasha.com/httpdocs/test4.php on line 9
[/snip]
Have you read and tr
t is binary safe.
>
> Matt
> - Original Message -
> From: Lee P. Reilly <[EMAIL PROTECTED]>
> Cc: <[EMAIL PROTECTED]>
> Sent: Tuesday, November 26, 2002 4:09 PM
> Subject: Re: [PHP] Upload problem - PC, *nix, and Max EOL characters
>
> >
> &g
No, fgets() reads to EOL, I use it all the time.
fread() will read to EOF, if you let it, as it is binary safe.
Matt
- Original Message -
From: Lee P. Reilly <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Tuesday, November 26, 2002 4:09 PM
Subject: Re: [PHP] Upload proble
Actually, there appears to be a solution on the PHP.web
[http://www.php.net/manual/en/function.fgets.php]
"Note: The length parameter became optional in PHP 4.2.0, if omitted, it would
assume 1024 as the line length. As of PHP 4.3, omitting length will keep reading
from the stream until it reaches
Hi,
Thanks for the reply. I appreciate your help. fgets() reads to the EOF; not the
EOL. Is there something similar to fgets() that I can use? Perhaps where I can
state explicity read the file until you encounter and EOL char?
Cheers,
Lee
Matt Vos wrote:
> Loop an fgets()
>
> i.e.
> $fp = fope
Loop an fgets()
i.e.
$fp = fopen($file)
while ($filerow = fgets($fp,1024)) /* Read 1024 bytes or to EOL, whichever
is first) */
{
$filerow = str_replace("; ","", $filerow);
$filerow = str_replace("# ","", $filerow);
$filerow = str_replace("\r","", $filerow);
$size = strlen($fil
Hi,
as far as i can follow you, you want to:
1. copy a file from position a to position b.
2. read it from position b.
3. and delete it at position b.
Why not read it directly from position a?
So what about:
$content = implode("", file($userfile));
Anyway: You should initialize $i in any
[EMAIL PROTECTED] wrote:
>
>Warning: Unable to open 'C:\\My Documents\\lyrics\\C_DTBS\\SLIME.TXT' for
>reading:
>
Has the webserver got permission to read this file? It does not seem to
be under the document root.
>No such file or directory in /home/tabzilla/public_html/doadd.php
>on line 89
>
Yeah I tried that as well, no dice, however here is what I the code that DID
work. Hope this helps anyone that is trying to accomplish much of the same.
Jas
wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> On Wednesday 22 May 2002 07:02, Jas wrote:
> > Ok here is my error message:
On Wednesday 22 May 2002 07:02, Jas wrote:
> Ok here is my error message:
> Warning: Unable to open '' for reading: No such file or directory in
> upload_done.php on line 9
>
> I have checked permissions on the folder and they are correct, my only
> guess is that upon doing several checks, session
Ok that didn't work, so far if I select a file other than a .jpg it returns
me an error which is what I need to happen, however if I select an image
with a .jpg extension for upload it tells me the upload was successful but
when I check the directory there is never anything there. Any other ideas
Take a look at move_uploaded_file()
http://www.php.net/manual/en/function.move-uploaded-file.php
Jas wrote:
>Ok here is my error message:
>Warning: Unable to open '' for reading: No such file or directory in
>upload_done.php on line 9
>
>I have checked permissions on the folder and they are corr
Try putting a hidden field like below in your form. Set the value (bytes) to
the size you want to be able to upload:
Kirk
> -Original Message-
> From: Frédéric Mériot [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, April 11, 2002 1:48 AM
> To: [EMAIL PROTECTED]
> Subject: [PHP] Upload pro
var_dump($HTTP_POST_FILES);
HTH
Andrey Hristov
- Original Message -
From: "Miguel Loureiro" <[EMAIL PROTECTED]>
To: "php-gen" <[EMAIL PROTECTED]>
Sent: Thursday, November 29, 2001 6:04 PM
Subject: [PHP] upload problem
> Hello all,
> when I want to do an upload ( form ENCTYPE="multipart
CC: <[EMAIL PROTECTED]>
>Subject: Re: [PHP] upload problem (uid)
>Date: Tue, 10 Apr 2001 16:15:48 -0700 (PDT)
>
>Are you sure it is uid 0? Unless your Apache is running as root it should
>be getting uploaded as the web server uid id. Use the
>move_uploaded_file() function to m
Are you sure it is uid 0? Unless your Apache is running as root it should
be getting uploaded as the web server uid id. Use the
move_uploaded_file() function to move the file into place.
-Rasmus
On Wed, 11 Apr 2001, b0ld b0lb wrote:
> Hi,
>
> if i upload via http the tempfile is written with
26 matches
Mail list logo