Date: 09/23/06 (PHP Development) Keywords: php, xml ok, so I am going to start with, this is a php4 based machine and I can't upgrade to 5 so I need a php4 solution. object(stdClass)(1) { ["voucher"]=> array(1) { [0]=> &object(stdClass)(5) { ["action"]=> array(1) { [0]=> string(6) "create" } ["partnerid"]=> array(1) { [0]=> string(4) "testing" } ["partnerkey"]=> array(1) { [0]=> string(4) "testing" } ["timestamp"]=> array(1) { [0]=> string(19) "2006-09-21 00:00:00" } } } This is the deal. I want to add to this list, but I am not sure how to do it. I am parsing using the XmlC class example from php.net I want to add a [errors] object with a few sub object (which will all be turned back into XML string afterwards and returned to the end users). I am not sure how to programmatically add this. Help please.. [edit]: I should add more information. I want to add [errors] to the same level as [timestamp] in the same object without having to rebuild the object.
|