|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2005-02-21 18:54 UTC] tony2001@php.net
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Fri Oct 24 13:00:02 2025 UTC |
Description: ------------ move_uploaded_file ignore destination if destination contains any relative path function will put file to default tmp(and no error message is sent, and strip relative path) , without(move to actual position) path or with absolute path will function move file to right destination I used php 4.3.10 safe_mode on base_dir I checked twice ;] I can tell this bug was not in 4.3.9 Reproduce code: --------------- $downloadDir="./tmp"; //local TMP dir in my space $file=$downloadDir."upload_".md5($HTTP_POST_FILES['file']['tmp_name']); move_uploaded_file($HTTP_POST_FILES['file']['tmp_name'],$file); //file is stored in /tmp/$file have to be in ./tmp/$file