开发者

alternative to json_decode before PHP 5.2

开发者 https://www.devze.com 2023-01-06 16:58 出处:网络
Is there a simple alternative to using json_decode function in php versi开发者_运维技巧ons prior to 5.2? I am feeling lazy at this time of night and can\'t be bothered to update php yet.

Is there a simple alternative to using json_decode function in php versi开发者_运维技巧ons prior to 5.2? I am feeling lazy at this time of night and can't be bothered to update php yet. Cheers.


You can find six alternatives at json.org


The comments for json_decode() include a few possible solutions.

Here's one that decodes by itself (though you shouldn't use it since it uses eval()! Oops.), and here's one that uses a PEAR module.


http://mike.teczno.com/JSON/JSON.phps

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号