我哈瓦一個字符串,其分裂數組值
$value ='xyz:101,xyz:102,xyz:103,xyz:104,xyz:105,ABC:201,xyz:202,xyz:203,xyz:204,xyz:205';
而且我想告訴喜歡
<table width='50%' border='1' cellpadding='10' cellspacing='10'>
<tr>
<th>Category</th>
<th>Code</th>
</tr>
<tr>
<td>XYZ</td>
<td>101</td>
</tr>
<tr>
<td>XYZ</td>
<td>102</td>
</tr>
<tr>
<td>XYZ</td>
<td>103</td>
</tr>
<tr>
<td>XYZ</td>
<td>104</td>
</tr>
<tr>
<td>XYZ</td>
<td>105</td>
</tr>
<tr>
<td>ABC</td>
<td>201</td>
</tr><tr>
<td>ABC</td>
<td>202</td>
</tr>
<tr>
<td>ABC</td>
<td>203</td>
</tr>
<tr>
<td>ABC</td>
<td>204</td>
</tr>
<tr>
<td>ABC</td>
<td>205</td>
</tr>
</table>
任何人可以幫助在表中該值我爲此
XYZ:101是關鍵:值對...?如果是值,那麼它是數組還是簡單的字符串? – pAsh
它是一個值對 –
數組或字符串? –