-2
我正在考試系統上工作,我遇到了一個問題以獲得正確的結果。 我想從答案陣列這個結果是匹配問題ID 466從std類多維數組中提取完整的數組php
(
[id] => 234
[firstChoice] => 2
[choice] => 2
[marked] =>
[strikethrough] => Array()
[highlights] =>
[guessed] =>
[difficulty] => easy
[numTimesChanged] =>
[timeElapsed] => 36
)
予有這種類型的答案的std類陣列。 我也有相同類型的數組。
Array(
[0] => stdClass Object
(
[id] => 234
[firstChoice] => 2
[choice] => 2
[marked] =>
[strikethrough] => Array
(
)
[highlights] =>
[guessed] =>
[difficulty] => easy
[numTimesChanged] =>
[timeElapsed] => 36
)
[1] => stdClass Object
(
[id] => 466
[firstChoice] => 3
[choice] => 3
[marked] =>
[strikethrough] => Array
(
)
[highlights] =>
[guessed] =>
[difficulty] => easy
[numTimesChanged] =>
[timeElapsed] => 5
)
)
什麼都有你_tri ed_? – bwoebi
如果可能的話,我會建議將ID設置爲數據生成的關鍵字。 –