dbillings Posted November 4, 2009 Share Posted November 4, 2009 Say you have a form with 10 select lists. Is there a way to blur() all select boxes with one line of code? So replace... document.formname.selectName1.blur() document.formName.selectName2.blur() document.formName.selectName3.blur() etc... with... document.formName.something to refer to all select fields.blur() I'm not sure if that makes sense or if there is a short cut to blur all of one field type in a give form. Thanks for any help with this. Link to comment https://forums.phpfreaks.com/topic/180346-solved-html-dom-select-blur-question/ Share on other sites More sharing options...
xtopolis Posted November 5, 2009 Share Posted November 5, 2009 How could they all have focus at once? If you want to remove focus from anywhere, set the focus to something specific and then blur that. AFAIK you can't focus on more than one object... http://www.java2s.com/Code/JavaScriptReference/Javascript-Methods/blurSyntaxParametersandNote.htm Link to comment https://forums.phpfreaks.com/topic/180346-solved-html-dom-select-blur-question/#findComment-951492 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.