Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/visual-studio-2012/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Php 使用wp_remote_post可以上载的文件的最大大小是多少?_Php_Wordpress - Fatal编程技术网

Php 使用wp_remote_post可以上载的文件的最大大小是多少?

Php 使用wp_remote_post可以上载的文件的最大大小是多少?,php,wordpress,Php,Wordpress,我使用wp_remote_post方法在amazon服务器上上传视频文件 我已尝试上载1 MB文件并获得以下响应: 上传文件之前的POST请求字段太大。 我可以在WordPress中使用cUrl上传大文件(高达100MB) 所以,我想知道使用wp_remote_post可以上传的最大文件大小是多少 谢谢。wp\u remote\u post()取决于服务器的默认设置值 您需要在php.ini中设置以下值 ; Maximum allowed size for uploaded files. upl

我使用wp_remote_post方法在amazon服务器上上传视频文件

我已尝试上载1 MB文件并获得以下响应:

上传文件之前的POST请求字段太大。

我可以在WordPress中使用cUrl上传大文件(高达100MB)

所以,我想知道使用wp_remote_post可以上传的最大文件大小是多少

谢谢。

wp\u remote\u post()取决于服务器的默认设置值

您需要在php.ini中设置以下值

; Maximum allowed size for uploaded files.
upload_max_filesize = 100M

; Must be greater than or equal to upload_max_filesize
post_max_size = 100M
或者您也可以通过.htaccess文件来完成

php_value upload_max_filesize 100M
php_value post_max_size 100M

谢谢你的回复。我在php.ini文件中有upload_max_filesize=0(无限上传限制)和post_max_size=1024M。请执行相同的操作,因为两者都使用并考虑作为post upload upload_max_filesize=1024M。我已更新php.ini并将upload_max_filesize=1024M设置为upload_max_filesize=1024M。但我也犯了同样的错误。