Adding/Updating ZVal Arrays to Object
| From: | Matthew C. Rice | Date: | Fri, 20 Feb 2009 19:31:50 +0000 |
| Subject: | Adding/Updating ZVal Arrays to Object | ||
| Groups: | php.internals | ||
| Request: | Send a blank email to internals+get-43129@lists.php.net to get a copy of this message | ||
Hello everyone,
I am building a custom PHP Extension. It is object based, and while the documentation seems to be lacking a little on this aspect in extensions, I haven't let that slow me down. I have used other extensions as examples, and done a great deal of searching around to find everything I have needed until now.
I currently have the following http://pastebin.com/m74c98b43 ( the start method ) in my classes __construct ( I actually use PHP_MALIAS to alias __construct to the function ) .. This works perfect. It creates a array in the object, just as I expect it to.
I can even print out the number of elements and their values in the debug function by passing $Obj->Property to it
The problem I am having is that I can't seem to figure out a way to append values on to the ZVal Array in another PHP_METHOD(). I have tried combinations of zend_hash_find() && zend_hash_update() to no avail. Is there anyone that might be able to point me in the right direction as to how to do this?Matthew C. Rice