Returning multi-dimensional arrays from within PHP modules
| From: | Thomas Wentzel | Date: | Mon, 05 Feb 2001 14:55:19 +0000 |
| Subject: | Returning multi-dimensional arrays from within PHP modules | ||
| Groups: | php.dev | ||
| Request: | Send a blank email to php-dev+get-45775@lists.php.net to get a copy of this message | ||
Hi,
I were refered to this list...
I found an old entry in the dev archive, explaining that I could achieve
my goals, by "for each inner array you
allocate a zval*, initialize it, add data to it, and add it to the
return value."
But how exactly do I add a zval?
My guess is add_assoc_resource but where do the integer come from?
Is it the returnvalue from array_init(allocatedZvalP)???
TIA
Thomas
-------------
Hi all,
I've been using array_init and add_assoc_xxx to return an array from
within my PHP module... But how would I go about returning the following
stucture
Array (Array (Name, Type, Size))
tia
T.