只是想知道是否有可能以一個PHP數組轉換爲JSON字符串 繼承人的下面的PHP數組:轉換PHP數組JSON字符串
array (
'players' => array (
'123' => '345'
'567' => '789'
),
'non_players' => array (
0 => '71558060',
1 => '14451395',
2 => '16428783',
3 => '12070702',
4 => '16872249',
5 => '10081837',
6 => '10000363',
7 => '10084478',
),
)
是否有可能轉換成JSON字符串?
你檢查https://www.google.co.in/search?q=INSERT+IGNORE&ie=utf-8&oe=utf-8&client= ubuntu&channel = fs&gfe_rd = cr&ei = 6dF9U5eZN4We_waRvIHgCw#channel = fs&q = php + array + to + json –
是的,它被稱爲[json_encode()](http://www.php.net/manual/en/function.json -encode.php) – Crackertastic
在發佈到SO之前請不要想。 :) –