From:             [EMAIL PROTECTED]
Operating system: Linux SUSE 7.2
PHP version:      4.0.6
PHP Bug Type:     Scripting Engine problem
Bug description:  File upload work only locally

I made a simple script to upload files but File upload works only locally,
i.e. on the same computer where the web server is. 
This is the script:
<?php
if ($HTTP_POST_FILES[upload][tmp_name]!="" ){
        
move_uploaded_file($HTTP_POST_FILES[upload][tmp_name],$HTTP_POST_FILES[upload][name]);

}else   echo"File lost!";
        phpinfo();
?>

And this is the html code for the form:
<form action="prendi_file.php" enctype="mutipart/form-data"
method="post">
file <input type="file" name="upload" >
<input type="submit" value="send" >
</form>

Uploading a file from the same computer where the web server is everything
goes right and the uploaded file is copied in the same directory of the
php script.
Connecting from another computer the  $HTTP_POST_FILES variable is not
set, as also shown by phpinfo().

Default temporary directory is /tmp and the privileges are ok (777)
I try to disable safe_mode but nothing changed.

Thank you
Vincent Brown

PS my configure line given by phpinfo() is
'./configure' '--prefix=/usr' '--bindir=/usr/bin' '--libdir=/usr/lib'
'--with-config-file-path=/etc' '--with-exec-dir=%{libdir}/php/bin'
'--with-pgsql=/usr' '--with-mysql=/usr' '--with-gd=yes'
'--with-tiff-dir=/usr' '--with-jpeg-dir=/usr' '--with-png-dir=/usr'
'--with-xpm-dir=/usr/X11R6' '--with-pdflib=/usr' '--with-ldap=yes'
'--with-zlib=yes' '--with-bz2' '--with-ttf' '--with-xml=no' '--with-t1lib'
'--with-sablot' '--with-readline' '--with-ftp' '--with-ndbm' '--with-gdbm'
'--with-mcrypt' '--with-gettext' '--with-mm' '--with-gd=yes'
'--with-qtdom=/usr/lib/qt-2.2.1/' '--enable-versioning' '--enable-yp'
'--enable-bcmath' '--enable-trans-sid' '--enable-inline-optimization'
'--enable-track-vars' '--enable-magic-quotes' '--enable-safe-mode'
'--enable-sockets' '--enable-sysvsem' '--enable-sysvshm' '--enable-shmop'
'--enable-calendar' '--enable-exif' '--enable-ftp' '--enable-memory-limit'
'--enable-filepro' '--enable-dbase' '--enable-ctype' '--disable-debug'
'--enable-force-cgi-redirect' '--enable-discard-path' '--enable-sigchild'
'--enable-gd-imgstrttf' '--with-openssl' '--with-swf=./dist/'
'--with-apxs=/usr/sbin/apxs' 'i386-suse-linux'
-- 
Edit bug report at http://bugs.php.net/?id=16463&edit=1
-- 
Fixed in CVS:        http://bugs.php.net/fix.php?id=16463&r=fixedcvs
Fixed in release:    http://bugs.php.net/fix.php?id=16463&r=alreadyfixed
Need backtrace:      http://bugs.php.net/fix.php?id=16463&r=needtrace
Try newer version:   http://bugs.php.net/fix.php?id=16463&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=16463&r=support
Expected behavior:   http://bugs.php.net/fix.php?id=16463&r=notwrong
Not enough info:     http://bugs.php.net/fix.php?id=16463&r=notenoughinfo
Submitted twice:     http://bugs.php.net/fix.php?id=16463&r=submittedtwice

Reply via email to