View Single Post
 
Old May 24th, 2005, 02:13 PM
shortt shortt is offline
Registered User
 
Join Date: May 2005
Location: , , .
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Default Object literal syntax

I am familiar with this type of literal object syntax:
Code:
var myObject = {"bindings": [
        {"ircEvent": "PRIVMSG", "method": "newURI", "regex": "^http://.*"},
        {"ircEvent": "PRIVMSG", "method": "deleteURI", "regex": "^delete.*"},
        {"ircEvent": "PRIVMSG", "method": "randomURI", "regex": "^random.*"}
    ]
};
as well as this, for arrays:
Code:
slides = [
    {url: 'slide0001.html', title: 'Looking Ahead'},
    {url: 'slide0008.html', title: 'Forecast'},
    {url: 'slide0021.html', title: 'Summary'}
];
but the following is new to me:
Code:
obj[‘on’ + event]
What does this mean? obj is an object, I think.

Thanks,
Tim