paraboul Posted February 27, 2009 Share Posted February 27, 2009 Hi, I started to play with SAPI of PHP and write some stuff. Sadly core API is not as documented as PHP userspace What is the difference between call_user_function and call_user_function_ex. Thanks Link to comment https://forums.phpfreaks.com/topic/147221-difference-between-call_user_function-and-call_user_function_ex/ Share on other sites More sharing options...
corbin Posted February 28, 2009 Share Posted February 28, 2009 Well, it looks as though it is called from an external binary (I would guess a lib), so I can't tell you much about what exactly the different in what the two functions do is.... I can tell you what parameters they take though, based on their prototypes in Zend/Zend_API.h ZEND_API int call_user_function(HashTable *function_table, zval **object_pp, zval *function_name, zval *retval_ptr, zend_uint param_count, zval *params[] TSRMLS_DC); ZEND_API int call_user_function_ex(HashTable *function_table, zval **object_pp, zval *function_name, zval **retval_ptr_ptr, zend_uint param_count, zval **params[], int no_separation, HashTable *symbol_table TSRMLS_DC); As you will see retval_ptr is doubley indirected in _ex, no_separation exists, and a symbol_table param can be passed. Of course, assuming you have the ability to search text files (and if you're modifying the PHP core or you're coding an extension I would hope you do), then I've told you nothing new. Link to comment https://forums.phpfreaks.com/topic/147221-difference-between-call_user_function-and-call_user_function_ex/#findComment-773097 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.