|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2005-09-14 08:14 UTC] sniper@php.net
[2005-09-22 01:00 UTC] php-bugs at lists dot php dot net
[2006-03-16 10:29 UTC] walther dot princee at centric dot nl
[2007-08-09 14:26 UTC] jeremiesaen at gmail dot com
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sun Oct 26 17:00:01 2025 UTC |
Description: ------------ There's bug that I found in PHP5.0.4 (I'm sorry if the problem has been fixed) This is the problem: for example: the $uploadfile=bring'iton.jpg and the result: iton.jpg it doesn't happen at PHP4 version, so I remigrate to PHP4 again. Reproduce code: --------------- <? include "connect.config.php"; $cwdvar=getcwd(); $cwdvar1=str_replace("\\","/",$cwdvar); $file_name = "$uploadFile_name"; echo "$uploadFile_name"; $file_name=str_replace("'","",$file_name); $copy = copy($uploadFile,$file_name); if($copy){ echo "<b>$file_name </b> upload succeed<br>"; $query_insert="INSERT INTO dirfiles (filename, dirpath) VALUES ('$file_name', '$cwdvar1')"; $query_res=mysql_query("$query_insert"); if($query_res){ echo "database updated"; } }else{ echo "<b>$file_name</b> database doesn't updated<br>"; } ?> Expected result: ---------------- i expect the result is bringiton.jpg (because there's an str_replace function) and I try to remigrate to PHP4, the result is bringiton.jpg Actual result: -------------- The result is iton.jpg (at PHP 5.0.4)