I have the following JS code:
window.Foo = {};
window.Foo.Name1 = function()
{
function Bar1(param1)
{
this.Name = param1;
}
}
var gMyBar = new Foo.Name1.Bar1("hello world");
alert(gMyBar.Name);
I'm getting the error "Foo.Name1.Bar1 is not a constructor" in my Firefox error console... what gives?