我试图在一个隐藏的输入框中发送一个Base64编码的图片(大约500KB),但是我一直收到错误提示。
501 Method Not Implemented
GET to /test.php not supported.
Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.
我的代码
<?php error_reporting(E_ALL) ?>
<html>
<head></head>
<body>
<form action="<?php echo $_SERVER['PHP_SELF'] ?>" method="POST">
<input type="hidden" name="image" value="{base64 encoded image}">
<input type="submit" name="" value="OK">
</form>
<?php if($_POST) {
echo '<pre>'.print_r($_POST, true).'</pre>';
} ?>
</body>
</html>
PS. 在本地主机上一切正常。
感谢您的帮助。
GET到/test.php
不支持?但是你说你正在进行POST
请求? - Marc B