note 41912 deleted from zend.variables by nlopess
| From: | nlopess@php.net | Date: | Mon, 26 Apr 2004 13:07:42 +0000 |
| Subject: | note 41912 deleted from zend.variables by nlopess | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-68819@lists.php.net to get a copy of this message | ||
Note Submitter: yinglw@163.com
----
If you want free after created, you can do this:
zval *new_var;
/* allocate and initialize new container */
MAKE_STD_ZVAL(new_var);
/* set type and variable contents here, see the following sections */
ZVAL_STRING(new_var, "123456", 1);
/* introduce this variable by the name "new_variable_name" into the symbol table */
zend_hash_update(
EG(active_symbol_table),
"new_var",
strlen("new_var") + 1,
&new_var,
sizeof(zval *),
NULL
);
zend_hash_del(
EG(active_symbol_table),
"new_var",
strlen("new_var") + 1);
FREE_ZVAL(new_var);