Kirby Bakken wrote:
> None of the servers I run on have PHP 5.3, and I have no idea when
> they'll be updated. The json_last_error function is in 5.3. What can I
> do to provide a temporary json_last_error function until my servers get
> updated to 5.3? Is there source available for json_last_error somewhere?
I don't believe you will be able to provide this functionality without
recreating the json_decode() function also.
json_last_error() looks like it retrieves information that is from the last
attempt to run json_decode() on a given string. My guess is that json_decode()
set an internal variable that json_last_error() picks up and returns.
Without having json_decode() say what the problem was/is then you can never
recreate the json_last_error() function.
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php