Jump to content

Functions: optional arguments


myron

Recommended Posts

you are using the correct format for function

 

function splitPageResults($query, $max_rows, $count_key = '*', $page_holder = 'page')

 

it will do wht you need to do

 

Did you read the OP? What he's after is not possible, really, just as the other two replies have said.

 

@myron - Your best bet is to pass in a NULL and test for that within your actual function body. If it's empty, assign it your default value.

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.