您将需要使用POST请求:
$.ajax({ url: '/script.php', type: 'POST', data: { value: 'some huge string here' }, success: function(result) { alert('the request was successfully sent to the server'); }});并在服务器端脚本中检索值:
$_POST["value"]
另外,您可能需要增加允许的请求大小。例如,在您的
.htaccess文件或您的文件中,您
php.ini可以设置以下
post_max_size值:
#set max post sizephp_value post_max_size 20M



