0
내가 한 내장 배열이 방법인쇄 다차원 배열과 스타일이
Array ( [6] => Array ( [id] => 6 [parent_id] => [text] => Top level comment [level] => 1 ) [1] => Array ( [id] => 1 [parent_id] => [text] => Top level comment [level] => 1 [children] => Array ( [2] => Array ( [id] => 2 [parent_id] => 1 [text] => Response to #1 ) [3] => Array ( [id] => 3 [parent_id] => 1 [text] => Response to #1 [children] => Array ( [4] => Array ( [id] => 4 [parent_id] => 3 [text] => Response to #3 ) ) ) [10] => Array ( [id] => 10 [parent_id] => 1 [text] => Response to #2 [children] => Array ( [11] => Array ( [id] => 11 [parent_id] => 10 [text] => Response to #10 [children] => Array ( [13] => Array ( [id] => 13 [parent_id] => 11 [text] => Response to #11 [children] => Array ( [14] => Array ( [id] => 14 [parent_id] => 13 [text] => Response to #13 ) ) ) ) ) [12] => Array ( [id] => 12 [parent_id] => 10 [text] => Response to #10 ) ) ) ) ) [5] => Array ( [id] => 5 [parent_id] => [text] => Top level comment [level] => 1 ) [9] => Array ( [id] => 9 [parent_id] => [text] => Top level comment [level] => 1 ) )
JSON
{"6":{"id":6,"parent_id":null,"text":"Top level comment","level":1},"1":{"id":1,"parent_id":null,"text":"Top level comment","level":1,"children":{"2":{"id":2,"parent_id":1,"text":"Response to #1"},"3":{"id":3,"parent_id":1,"text":"Response to #1","children":{"4":{"id":4,"parent_id":3,"text":"Response to #3"}}},"10":{"id":10,"parent_id":1,"text":"Response to #2","children":{"11":{"id":11,"parent_id":10,"text":"Response to #10","children":{"13":{"id":13,"parent_id":11,"text":"Response to #11","children":{"14":{"id":14,"parent_id":13,"text":"Response to #13"}}}}},"12":{"id":12,"parent_id":10,"text":"Response to #10"}}}}},"5":{"id":5,"parent_id":null,"text":"Top level comment","level":1},"9":{"id":9,"parent_id":null,"text":"Top level comment","level":1}}
가장 쉬운 그것을 반향 방법과 스타일은 무엇입니까? reddit처럼 말하십시오. 보기 파일에서 스타일을 지정하고 싶습니다.
당신이 공유하고 Whould? 나는 아이들의 숫자 = x 때문에 무엇을 해야할지 모르겠다. – Martin