3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php echo "<pre>"; $string = '[{"self":{"tag_id":"442","tag_name":"\u886c\u886b","parent_id":"8190","alias":"Shirt,\u886c\u8863","top_id":"310"},"parents":[{"tag_id":"310","tag_name":"\u670d\u9970\u98ce\u5c1a"},{"tag_id":"415","tag_name":"\u8863\u8863"},{"tag_id":"8190","tag_name":"\u4e0a\u88c5"},{"tag_id":"442","tag_name":"\u886c\u886b","parent_id":"8190","alias":"Shirt,\u886c\u8863","top_id":"310"}]},{"self":{"tag_id":"2297","tag_name":"\u98ce\u8863","parent_id":"1915","alias":"","top_id":"310"},"parents":[{"tag_id":"310","tag_name":"\u670d\u9970\u98ce\u5c1a"},{"tag_id":"415","tag_name":"\u8863\u8863"},{"tag_id":"1915","tag_name":"\u5927\u8863"},{"tag_id":"2297","tag_name":"\u98ce\u8863","parent_id":"1915","alias":"","top_id":"310"}]},{"self":{"tag_id":"3911","tag_name":"\u9999\u6e2f","parent_id":"6","alias":"Hong Kong,hong kong","top_id":"6"},"parents":[{"tag_id":"6","tag_name":"\u65e0\u7ed3\u6784\u6807\u7b7e"},{"tag_id":"3911","tag_name":"\u9999\u6e2f","parent_id":"6","alias":"Hong Kong,hong kong","top_id":"6"}]},{"self":{"tag_id":"7317","tag_name":"\u84dd\u8272","parent_id":"6","alias":"Blue,blue","top_id":"6"},"parents":[{"tag_id":"6","tag_name":"\u65e0\u7ed3\u6784\u6807\u7b7e"},{"tag_id":"7317","tag_name":"\u84dd\u8272","parent_id":"6","alias":"Blue,blue","top_id":"6"}]},{"self":{"tag_id":"9714","tag_name":"\u5434\u541b\u5982","parent_id":"1383","alias":"","top_id":"1383"},"parents":[{"tag_id":"1383","tag_name":"\u5a07\u70b9\u660e\u661f"},{"tag_id":"9714","tag_name":"\u5434\u541b\u5982","parent_id":"1383","alias":"","top_id":"1383"}]}]'; print_r(json_decode($string));
Output for 5.2.0 - 5.6.28, hhvm-3.10.0 - 3.12.0, 7.0.0 - 7.1.0
<pre>Array ( [0] => stdClass Object ( [self] => stdClass Object ( [tag_id] => 442 [tag_name] => 衬衫 [parent_id] => 8190 [alias] => Shirt,衬衣 [top_id] => 310 ) [parents] => Array ( [0] => stdClass Object ( [tag_id] => 310 [tag_name] => 服饰风尚 ) [1] => stdClass Object ( [tag_id] => 415 [tag_name] => 衣衣 ) [2] => stdClass Object ( [tag_id] => 8190 [tag_name] => 上装 ) [3] => stdClass Object ( [tag_id] => 442 [tag_name] => 衬衫 [parent_id] => 8190 [alias] => Shirt,衬衣 [top_id] => 310 ) ) ) [1] => stdClass Object ( [self] => stdClass Object ( [tag_id] => 2297 [tag_name] => 风衣 [parent_id] => 1915 [alias] => [top_id] => 310 ) [parents] => Array ( [0] => stdClass Object ( [tag_id] => 310 [tag_name] => 服饰风尚 ) [1] => stdClass Object ( [tag_id] => 415 [tag_name] => 衣衣 ) [2] => stdClass Object ( [tag_id] => 1915 [tag_name] => 大衣 ) [3] => stdClass Object ( [tag_id] => 2297 [tag_name] => 风衣 [parent_id] => 1915 [alias] => [top_id] => 310 ) ) ) [2] => stdClass Object ( [self] => stdClass Object ( [tag_id] => 3911 [tag_name] => 香港 [parent_id] => 6 [alias] => Hong Kong,hong kong [top_id] => 6 ) [parents] => Array ( [0] => stdClass Object ( [tag_id] => 6 [tag_name] => 无结构标签 ) [1] => stdClass Object ( [tag_id] => 3911 [tag_name] => 香港 [parent_id] => 6 [alias] => Hong Kong,hong kong [top_id] => 6 ) ) ) [3] => stdClass Object ( [self] => stdClass Object ( [tag_id] => 7317 [tag_name] => 蓝色 [parent_id] => 6 [alias] => Blue,blue [top_id] => 6 ) [parents] => Array ( [0] => stdClass Object ( [tag_id] => 6 [tag_name] => 无结构标签 ) [1] => stdClass Object ( [tag_id] => 7317 [tag_name] => 蓝色 [parent_id] => 6 [alias] => Blue,blue [top_id] => 6 ) ) ) [4] => stdClass Object ( [self] => stdClass Object ( [tag_id] => 9714 [tag_name] => 吴君如 [parent_id] => 1383 [alias] => [top_id] => 1383 ) [parents] => Array ( [0] => stdClass Object ( [tag_id] => 1383 [tag_name] => 娇点明星 ) [1] => stdClass Object ( [tag_id] => 9714 [tag_name] => 吴君如 [parent_id] => 1383 [alias] => [top_id] => 1383 ) ) ) )
Output for 5.0.0 - 5.1.6
<pre> Fatal error: Call to undefined function json_decode() in /in/0sK2D on line 5
Process exited with code 255.
Output for 4.4.5 - 4.4.9
<pre> Fatal error: Call to undefined function: json_decode() in /in/0sK2D on line 5
Process exited with code 255.
Output for 4.3.2 - 4.4.4
<pre> Fatal error: Call to undefined function: json_decode() in /in/0sK2D on line 5
Process exited with code 255.
Output for 4.3.0 - 4.3.1
<pre> Fatal error: Call to undefined function: json_decode() in /in/0sK2D on line 5