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

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

Save User Inputs while javascript reloading!
hi..
i have written a PHP code in which i reload the page when user selects a value in dropdown..

Different actions for different parts of a string
<?php
function dosomething($string, $else = '') {
if (empty($else))
$string

Help with forum quoting?
Hi im working on a forum and I have alomost finished it but i want a user quote system like twitter

TCP Sending Unsigned Char...
Hi...

I want to send over tcp/ip some data, i have the data in hexadecimal, and when i tr

Parse error: parse error in C:wampwwwlogspagesmembers.php on line 16
I dont see the problem with this, I always get Parse error: parse error in C:wampwwwlogspagesme

Call Screen statement Error
Dear Experts,

is there any setting that needs to be done before creating any dialog progr

Login Control?!
I have a Web Site that uses the login control also I have set the destinationurl to the page I want

wav to mp3 + goDaddy
I need to convert wav files to mp3s. From what I have found so far one way to do it is to have my PH

Simple AND question
Hello,

I've got following code:

Code: if(strpos($row[13],"http://")

System copy error in RUN ABAP REPORT PHASE
Hi,
I am performing system copy on my test server. I have previously taken export of JAVA + A

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