I send a base64 encoded string using $.post
. Its length is 1000000+
(less than 2M)
When I grab it with PHP $_POST it crashes (504 or 424 error returns). Each returns after a big timeout.
Its ok for lower string length < 900000
. But for length 900000
the response timeout is 15-30 seconds!!!
To check it I used this code:
javascript:
var string = '...';
console.log(string.lenght);
$.post("save.php", {
data: string
}, function(result){
console.log(result);
});
save.php:
$data = $_POST['data'];
echo strlen($data);
On my local machine everything is ok. Can anyone explain whats happening?
Why it takes so long? Why can't I normally send data over 900000
chars?
I also checked server properties:
memory_limit 128M
post_max_size 100M
max_input_vars 10000
upload_max_filesize 100M