Odd JavaScript getElementsByName undefined error -


okay, i've got missing or i'm crazy. here's code i'm having issue with, inside onchange event:

console.log( (this.parentnode.parentnode) ); // fine prints elements  console.log( (this.parentnode.parentnode).getelementsbyname('otherposition[]') ); // gives me undefined error  (this.parentnode.parentnode).getelementsbyname('otherposition[]')[0].style.opacity = '1'; // same error. 

getelementsbyname method of document, elements doesn't have such method.


Comments

Popular posts from this blog

c# - Send Image in Json : 400 Bad request -

jquery - Fancybox - apply a function to several elements -

An easy way to program an Android keyboard layout app -