In PHP, how can I detect that input vars were truncated due to max_input_vars being exceeded?
apache, php, security
Solution
A "close enough" method would be to check `if( count($_POST, COUNT_RECURSIVE) == ini_get("max_input_vars"))`
This will cause a false positive if the number of POST vars happens to be exactly on the limit, but considering the default limit is 1000 it's unlikely to ever be a concern.
Problem
I know that an `E_WARNING` is generated by PHP PHP Warning: Unknown: Input variables exceeded 1000 But how can I detect this in my script?