I am trying to define a function which has default values for two of the arguments being passed to the function, but it does not want to accept variables as the default values. If I have static values, the defaults work fine, but as soon as I put variables, it breaks...
This is the version that works with static values
function executeQuery($query,$start=0,$limit=200)
{ ...... }
Thsi is the version with variables that is not working
function executeQuery($query,$start=$x,$limit=$y)
{ ...... }
Anyone knows how to make a function take variables as default values or if it is possible at all in php?
Thanks