I found the answer at zend.com and provided a group of examples. here I download: sums (array_experiments) {zval * new_element; MAKE_STD_ZVAL (new_element );
I found the answer at zend.com and provided a group of examples. download here: http://www.zend.com/apidoc/examples.tar.gz
Returns an array.
PHP_FUNCTION (array_experiments)
{
Zval * new_element;
MAKE_STD_ZVAL (new_element );
Array_init (return_value );
ZVAL_LONG (new_element, 10 );
Zend_hash_index_update (HASH_OF (return_value), 3, (void *) & new_element, sizeof (zval *), NULL );
Add_next_index_long (return_value, 20 );
}
For specific functions, see The zend api in the php Manual. However, this part of content has not been translated into Chinese... I can't understand it when I see it. it's so bad English that I can't understand it when I use Kingsoft. I'm waiting for that guy to translate it... haha