Vote #63609
完了Use of Prototype's Element-methods (like this.up("form"))
0%
説明
In /views/issues/_list.rhtml for example you use "this.up('form')". Actually the up-method is not available on the element itself, but only by the element, when it is returned by the $() method.
Quote from the Prototype-Documentation:
Prototype adds many convenience methods to elements returned by the $() function.
So, the correct way would be using: $(this).up('form') or Element.up(this,'form')
In IE7 the up method is actually not available on "this". In your case it's working "accidentially", because there is a call to $$('.hascontextmenu') executed somewhere in context_menu.js during page load, and by that the up-method is added to all DOM elements.
To better understand the problem check out this example (make sure to set the correct path and filename to prototype.js)
Regards,
Chris
journals
Fixed in r1667.
Thanks for your tip.
--------------------------------------------------------------------------------