<?php function foo() {
$numargs = func_num_args(); if ($numargs > 2) {
echo "First: ". func_get_arg(0). "\n";
echo "Second: ". func_get_arg(1). "\n";
echo "Third: ". func_get_arg(2). "\n";
} return $numargs;
}
$n = foo (10, 15, 20); //傳入 3 個參數 echo $n; ?>

Felix 發表在 痞客邦 PIXNET 留言(0) 人氣()