#20851 [Fbk->Opn]: windows and upload_tmp_dir

From: Date: Sun, 26 Jan 2003 17:06:16 +0000
Subject: #20851 [Fbk->Opn]: windows and upload_tmp_dir
References: 1  Groups: php.doc 
Request: Send a blank email to phpdoc+get-969351320@lists.php.net to get a copy of this message
ID: 20851 User updated by: fernando.conceicao@terra.com.br Reported By: fernando.conceicao@terra.com.br -Status: Feedback +Status: Open Bug Type: Documentation problem Operating System: Windows Millenium PHP Version: 4.2.3 New Comment: I read the changelog and for me appear that this is something like the bug 20725, that was fixed in PHP 4.3.0, since I try do it again in 4.3.0 and the PHP put the files on C:/windows/temp, but this don´t work on 4.2.3. Thanks. Previous Comments: ------------------------------------------------------------------------ [2003-01-21 12:17:55] philip@php.net According to the source there are defaults. Here are some comments found within hp_open_temporary_file.c: /* We can't count on the environment variables TEMP or TMP, * and so must make the Win32 API call to get the default * directory for temporary files. Note this call checks * the environment values TMP and TEMP (in order) first. */ That call is made to GetTempPath. Run msconfig.exe and tell us what the above environment variables are set to on your system. ------------------------------------------------------------------------ [2002-12-05 21:34:26] fernando.conceicao@terra.com.br In a mailing list the people tell they can´t make the example of file upload work, only who uses windows. So a begin work on this and discover why. If you don´t define upload_tmp_dir in php.ini, appears that php don´t know where to put, or it puts the file but don´t know where so $_FILES['userfile']['name'] return the correct value, but $_FILES['userfile']['tmp_name'] comes empty and you can´t move the file. Note that I don´t have anything in TMPDIR too. The people on windows "must" set the upload_tmp_dir in php.ini, without this can´t upload a file. ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=20851&edit=1

« previous php.doc (#969351320) next »