|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2005-10-19 23:51 UTC] tony2001@php.net
[2005-10-27 01:00 UTC] php-bugs at lists dot php dot net
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Fri Oct 24 04:00:01 2025 UTC |
Description: ------------ The problem is below: After a lot of validations i used the function move_uploaded_file on an if instruction, and it returned false, the error returned was 0, and it means "Its all Ok! Your file have been moved!", but there was no file uploaded.. And YES i have all permissions and how i said the archieve was valid. Reproduce code: --------------- } elseif (!($fcd_medicamento > 0)){ $msg_erro = "Choose a medication to associate with the file!"; } elseif ((move_uploaded_file($farq_pdf['tmp_name'], "/web/adm/capp/pdf/ ".$farq_pdf['name']))and (move_uploaded_file($farq_pdf2['tmp_name'], "/web/adm/capp/pdf/ ".$farq_pdf2['name']))) { $sql = "UPDATE sps_medicamento SET arq_resumido='".$farq_pdf['name']."', arq_completo='".$farq_pdf2['name']."' WHERE cd_medicamento = $fcd_medicamento"; if(!$DBcon->query($sql)){ echo "<b>Problem in the SQL instruction <br>n.o ".$DBcon->erro_num."</b>---> ".$DBcon->erro_msg."<br>"; Expected result: ---------------- Well i expected to see an error thats not 0, because its mean "No error" or to upload the file. Actual result: -------------- The "no error" number error have been printed(0), and the file haven't been uploaded