On May 31, 8:10 am, Ricardo <ricardob...@gmail.com> wrote: > myFunction() > and > window.myFunction > > are not necessarily the same. the first one will look up the scope > chain and use the first ocurrence, it doesn't go directly to the > window object. The second looks up the scope chain too and uses the first property named window that it finds. It may not be the window you think it is. > var x = 3; > (function(){ > var x = 5; > alert(x);})(); > > alert(x); > > Again, this is basic javascript Basic ECMAScript. -- Rob
- [jQuery] Re: calling functions between multiple document ... waseem sabjee
- [jQuery] Re: calling functions between multiple docu... Brian FitzGerald
- [jQuery] Re: calling functions between multiple ... waseem sabjee
- [jQuery] Re: calling functions between multiple ... Kean
- [jQuery] Re: calling functions between multi... MorningZ
- [jQuery] Re: calling functions between m... waseem sabjee
- [jQuery] Re: calling functions between m... Ricardo
- [jQuery] Re: calling functions betw... waseem sabjee
- [jQuery] Re: calling functions betw... MorningZ
- [jQuery] Re: calling functions betw... Ricardo
- [jQuery] Re: calling functions betw... RobG