Forum Moderators: open
Is the recommendation to stick to valid variable names and are there any docs that explain this?
Thanks.
hello = new Object()
// hello.123a //XXX
hello['123a'] = 1;
hello['if'] = 2;
hello['kippers & custard']// alternatively
hello =
{
'123a': 1,
'if': 2,
'kippers & custard': 3
}
Is the recommendation to stick to valid variable names?
No official one, but it's easier to write:
myObject.doodah
than
myObject['doo dah']
are there any docs that explain this?
Voila
I've seen a discrepancy between IE and Netscape
Interesting. Can you give us more?