Jump to content

custom properties


astralaaron

Recommended Posts

Hi I am trying to understand custom properties a little better. all I am trying to do is set a focused to true or false if they are clicked on a text area. I can accomplish it without the custom properties but I am just trying to learn var elm2; elm2 = document.forms['quickmessage'].elements['email']; elm2.focused=false; elm2.onfocus=function() { this.focused=true; alert('test'); alert(this.focused);}; elm2.onblur=function() { this.focused=false;}; the onfocus alerts test and false every time

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...