Friday, July 5, 2019

javascript: define a variable in a function

In PHP I can do something like this:



public myFunction($variable=0) {
//Do some stuff
}



In Javascript, the following does not work:



var myFunction = function(variable=0 )
{

//do some stuff...

};

No comments:

Post a Comment

plot explanation - Why did Peaches' mom hang on the tree? - Movies & TV

In the middle of the movie Ice Age: Continental Drift Peaches' mom asked Peaches to go to sleep. Then, she hung on the tree. This parti...