<html>
<head>
<title>file uploader</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body>
<p align="center">Fileupload system</p>
<p align = "center">
<form method="post" action="upload.php" enctype="multipart/form-data">
<input type="file" name="myfile"><br><br>
<input type="submit" value="upload">
<input type="reset" value="reset">
</form>
</p>
</body>
</html>
<?php
$upload_file = $_FILES["myfile"]["name"];
if (move_uploaded_file($_FILES["myfile"]["tmp_name"], $upload_file)) {
echo "<strong>upload ok</strong><hr>";
} else {
echo "upload failed";
}
?>
curl -A "Mozilla/4.0" -F "myfile=@logo.jpg" "http://192.168.1.100/upload.php
欢迎光临 曲径通幽论坛 (http://www.groad.net/bbs/) | Powered by Discuz! X3.2 |