I wanted to make an admin page on my site so I can upload images using web admin interface and so that I don't have to go through FTP upload. Here is my stripped down code for uploading :
<form enctype="multipart/form-data" action="index.php" method="post"> <input type="hidden" name="MAX_FILE_SIZE" value="100000" /> Upload : <input name="picture" type="file" /><br /> <input type="submit" value="Upload" /> </form>
But the thing is that it does not work when I click Upload button. The $_POST and $_FILES variables are empty. I checked by using print_r($_POST) and print_r($_FILES). The result is that it prints only Array()
I Googled and found many people facing this problem but could not find any solution. I tested on WAMP on Windows Vista, then tested on Ubuntu but nothing works.
Please suggest me some solutions or other methods of uploading a file through web interface.
Thanks.

Help



Back to top









