6
rated 0 times
[
11]
[
5]
/ answers: 1 / hits: 33916
/ 13 Years ago, sat, june 18, 2011, 12:00:00
In javascript is there a difference between using
if (foo.length > 0) {
//run code involving foo
}
and
if (foo) {
//run code involving foo
}
If so, could someone please explain the difference and an example where they would not be the same?
More From » variables