$dir = dirname(__FILE__) . '\\' . $_FILES['inputfile']['name']; move_uploaded_file($_FILES['inputfile']['tmp_name'], $dir); 
  • what specifically does not work, fashionable in more detail, add a printout of the $ _FILES variable, show the relevant sections of phpinfo - Yuri
  • Check the logs, and the tmp , perhaps move_uploaded_file trying to move the file to a directory that does not exist. - Kosta B.
  • The file does not move, but the folder is - AimBot
  • one
    Why after the full path, write 2 slashes, and then the file name? For the place of 2 slashes, write DIRECTORY_SEPARATOR , if you use php 5.3 and higher, for the place dirname , use __DIR__ . - And
  • one
    Usually such a mistake happens from the wrong way or the lack of rights to write to the directory - Ivan Bolnikh

0