Form.Element function getValue is throwing
"VM43674 prototype.js:6476 Uncaught TypeError: Cannot read property 'toLowerCase' of undefined
at getValue (VM43674 prototype.js:6476)
at Object.insert (VM43675 insertLink.js:11)
at InsertLink (selectLink.aspx:44)
at :1:2"
Prototype.js build version 1.7.3
This is due to wrapping the element in a JQuery object and then trying to directly access a property of the element.
Removing the JQuery wrapper fixed it for me but you may want to use element.prop("tagName").toLowerCase();. If you take the src in that direction then be wary that many of the functions the element are passed into will not expect a JQuery object and will also throw errors.
Form.Element function:1:2"
getValue
is throwing "VM43674 prototype.js:6476 Uncaught TypeError: Cannot read property 'toLowerCase' of undefined at getValue (VM43674 prototype.js:6476) at Object.insert (VM43675 insertLink.js:11) at InsertLink (selectLink.aspx:44) atPrototype.js build version 1.7.3
This is due to wrapping the element in a JQuery object and then trying to directly access a property of the element. Removing the JQuery wrapper fixed it for me but you may want to use
element.prop("tagName").toLowerCase();
. If you take the src in that direction then be wary that many of the functions the element are passed into will not expect a JQuery object and will also throw errors.