an interesting question


Posted on 16th Feb 2014 07:03 pm by admin

Greetings folks, got to ask an interesting question...

let say
i have created a function something like
Did you know?Explore Trending and Topic pages for more stories like this.

function xxx($a=4, $b, $c=4) {


}


now, is there any way to call this function so that i only send the required parameter (ie; $b) while bypassing the other two parameters ($a , $c), ie; to let them use their default values.

i tried,
xxx( , 55, );

ie; i bypassed the params that i want to use their default values, but i can't do this way, php gives some error. Is there any other way?? any idea?
No comments posted yet

Your Answer:

Login to answer
290 Like 43 Dislike
Previous forums Next forums
Other forums

mysqli_fetch_assoc returns multiple arrays, how to return a single array
Hello, I am using mysqli_fetch_assoc which is returning multiple rows, so it looks like:

Code

Comparing MySql data and arrays.
I have a mysql table set up like this:
idsubjectbodyuseriddatetimetags1blog subjectblog body111|2

Delete records not in top 15
Hi,

I'm creating a hall of fame page in my game and the page will only display the top 15 sco

Content-Disposition: attachment; filename=... not working as i thought it should
taken the following code from the php.net site the script is not working.

what is not happeni

How to add an image/C++ OpenGL?
Hi,

I have been trying to look online for this and, so far, I haven't found anything usef

Save data in input fields when they press "BACK BUTTON"
Hi, this is html form: And let's say they get a error "Please enter ur title must be more then

script is pulling more then they have....
I have this script for my game where they can change there race. This will cost them 2,500 points. H

Need a Timecode Class...
Not a Time Stamp, Time Code. Format is a bit different. HH:MM:SS:FF where FF is Frames. I dont re

All possible combinations of String in PL/SQL
Hi All,

Could you please explain the logic of getting all possible combinations of String

Passing PHP variables from one page to another
Hello-

I'm having trouble figuring out how to transport a variable from one php file to anoth

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash