PHP
downloads | documentation | faq | getting help | mailing lists | reporting bugs | php.net sites | links | conferences | my php.net

search for in the

call_user_method> <Κλάσεις/Αντικείμενα
Last updated: Sun, 25 Nov 2007

view this page in

call_user_method_array

(PHP 4 >= 4.0.5, PHP 5)

call_user_method_array — Καλεί μια μέθοδο με ένα array από παραμέτρους [deprecated]

Περιγραφή

mixed call_user_method_array ( string $method_name , object $obj [, array $paramarr ] )
Warning

Η συνάρτηση call_user_method_array() είναι deprecated από την έκδοση PHP 4.1.0, αντί αυτής χρησιμοποιήστε το call_user_func_array() με τη σύνταξη array(&$obj, "method_name").

Καλεί τη μέθοδο method_name του ορισμένου από το χρήστη αντικειμένου obj , χρησιμοποιώντας τις παραμέτρους μέσα στο paramarr array.

Δείτε επίσης: call_user_func_array(), και call_user_func().



add a note add a note User Contributed Notes
call_user_method_array
leonwinter at gmail dot com
02-Oct-2006 04:45
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.

call_user_method> <Κλάσεις/Αντικείμενα
Last updated: Sun, 25 Nov 2007
 
 
show source | credits | stats | sitemap | contact | advertising | mirror sites