dan_t Posted July 5, 2010 Share Posted July 5, 2010 This code is for a file upload, but how do I put the files(images) in a folder, somewhere in the server? I know near to nothing of javascript, just a basic validation. <form name="form1" enctype="multipart/form-data" method="post" action="<?php echo $_SERVER['PHP_SELF']; ?>"> <label for="upload[]">File 1:</label> <input type="file" name="upload[]" size="30"><br> <label for="upload[]">File 2:</label> <input type="file" name="upload[]" size="30"><br> <label for="upload[]">File 3:</label> <input type="file" name="upload[]" size="30"><br> <!-- Add here more file fields if you need. --> </form> A Quote Link to comment Share on other sites More sharing options...
phpSensei Posted July 5, 2010 Share Posted July 5, 2010 move_uploaded_file ( string $filename , string $destination ) the 2nd param is where you tell the function to place the file which you are uploading. Heres a tutorial http://www.tizag.com/phpT/fileupload.php Quote Link to comment Share on other sites More sharing options...
dan_t Posted July 5, 2010 Author Share Posted July 5, 2010 Thanks phpSensei I'll give it a try. Quote Link to comment Share on other sites More sharing options...
phpSensei Posted July 5, 2010 Share Posted July 5, 2010 Thanks phpSensei I'll give it a try. Np.. If this has helped solve your problem mark it as solved , if you have more questions then come back to this thread, ill check back to see if you have gotten it. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.