youYou can use a function with a undefined number of argumentsfunctions with a undefined number of arguments using the func_get_args().
<?php function test() { $args = func_get_args(); echo $args[2]; // will print 'd' echo $args[1]; // will print 3 } test(1,3,'d',4); ?>