Jump to content

[SOLVED] Variable number of parameters passed to a method


voidstate

Recommended Posts

You can have functions that deal with different amount of variables, it's not too hard to do that either.

Check the "Variable-length argument lists" section in here, it will tell you what functions you need to use:

http://www.php.net/manual/en/functions.arguments.php

 

But I think it's easier to store all of the data in an array and pass that array. You can do much more when it's in an array.

 

Orio.

 

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.