[ create a new paste ] login | about

Link: http://codepad.org/Qm202eOv    [ raw code | output | fork ]

gnel - PHP, pasted on Nov 25:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
<?php

class tempClass {
   function someFunction() {
      $tempArray = array('functionName' => 'tempFunction');
      call_user_func(array($this, $tempArray['functionName']));
   }

   function tempFunction() {
      echo "inside function";
   }
}

$a = new tempClass();
$a->someFunction();

?>


Output:
1
inside function


Create a new paste based on this one


Comments: