Some additional JSFiddle links that I produced afterwards to experiment with timing around when the browser would create its scope chains. It turns out browsers don't tend to create scope chains until the first time the event is fired.
In this example we have a button in a form. We can check its scope first, then change it, then check it again to see one behavior. We can then change scope and execute it to see a different behavior. http://jsfiddle.net/oko08kaw/
This example switches us from one form to another, which is a slightly more complicated behavior but achieves similar results. http://jsfiddle.net/p7bu92jw/2/