Posted
about 14 years
ago
by
|
Posted
about 14 years
ago
by
uhhhh
this is a virus
|
Posted
about 14 years
ago
by
test test
your_stuff('vicky');
|
Posted
about 14 years
ago
by
test test
your_stuff('here');
|
Posted
about 14 years
ago
by
bitPlaftwat
|
Posted
about 14 years
ago
by
ProownCibbowl
|
Posted
about 14 years
ago
by
Lcf.vs
Me>
var test;
test=[]; // true
test=[[]]; // true
test=[new Array()]; // true
test=new Array(); // true
test=new Array([]); // true
test=new Array(new Array()); // true
test[1]=3; // true
test={}; //false
test[0]=1; //false
What else?
|
Posted
about 14 years
ago
by
Me
@Lcf.vs: You can find an answer to your question here http://phpjs.org/functions/is_array:437#comment_112008
|
Posted
about 14 years
ago
by
Lcf.vs
Why complicate?
function isArray(supposedArray){
return supposedArray instanceof Array;
}
|
Posted
about 14 years
ago
by
Rafał Kukawski
@dude: Math.floor(value) !== value|value
floor(-10.5) === -11
(-10.5|-10.5) === -10
Your approach is only valid for positive numbers.
|