ID: 22105 Updated by: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] -Status: Open +Status: Feedback Bug Type: Directory function related Operating System: Linux PHP Version: 4.2.2 New Comment:
Please try using this CVS snapshot: http://snaps.php.net/php4-STABLE-latest.tar.gz For Windows: http://snaps.php.net/win32/php4-win32-STABLE-latest.zip Previous Comments: ------------------------------------------------------------------------ [2003-02-07 04:39:47] [EMAIL PROTECTED] $tmp = "xx/yy"; $parts = explode("/",$tmp); for($i=0;$i<count($parts);$i++) { $directory = 'files'; //my base-dir //strange loop to show the error for($j=0;$j<=$i;$j++) $directory = $directory . '/' . $parts[$j]; echo 'before :: ' . $directory . '<br>'; @mkdir($directory,0775); echo 'after :: ' . $directory . '<br>'; } outputs: before :: files/xx after :: files/xx before :: files/xx/yy after :: files/xxyy The last line has the error. As you can see mkdir() changes the variable. Even if the rest of the code is buggy ( ;) ) this shouldn't happen :) - bram ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=22105&edit=1