1<?php
2$a = array ('a' => 'apple', 'b' => 'banana', 'c' => array ('x', 'y', 'z'));
3echo "<pre>";
4print_r ($a);
5echo "</pre>";
6?>
7
8Output:
9
10Array
11(
12 [a] => apple
13 [b] => banana
14 [c] => Array
15 (
16 [0] => x
17 [1] => y
18 [2] => z
19 )
20)
21
1$class_methods = get_class_methods('myclass');
2// or
3$class_methods = get_class_methods(new myclass());
4foreach ($class_methods as $method_name)
5{
6 echo "$method_name<br/>";
7}