/ Published in: PHP
Expand |
Embed | Plain Text
class objArray { function __construct($data=null, &$node=null) { foreach ( $data as $key => $value ) { { if (! $node ) { $node =& $this; } $node->$key = new stdClass(); self::__construct($value,$node->$key); } else { if (! $node ) { $node =& $this; } $node->$key = $value; } } } }
You need to login to post a comment.
