Delicious Bookmark this on Delicious Share on Facebook SlashdotSlashdot It! Digg! Digg



PHP : Function Reference : Class/Object Functions : call_user_method_array

call_user_method_array

Call a user method given with an array of parameters [deprecated] (PHP 4 >= 4.0.5, PHP 5)
mixed call_user_method_array ( string method_name, object &obj, array paramarr )


Code Examples / Notes » call_user_method_array

leonwinter

If you this function will be deleted in future php releases you can use this function:
<?
      function _call_user_method_array($name, $obj, $params) {
          // get params
          $txt = "";
          foreach($params as $nr => $el) {
              $txt.='$params['.$nr."], ";
          }
          $txt = substr($txt, 0, strlen($txt)-2);
          // run it
          return eval('return call_user_method($name, $obj, '.$txt.');');          
      }
?>
Hope this helps somebody.


Change Language


Follow Navioo On Twitter
call_user_method_array
call_user_method
class_exists
get_class_methods
get_class_vars
get_class
get_declared_classes
get_declared_interfaces
get_object_vars
get_parent_class
interface_exists
is_a
is_subclass_of
method_exists
property_exists
eXTReMe Tracker