I have an input box that that is part of a form . depending on some circumstances I want to add an Onfocus element to my form but i want to do this using js and only if needed. I have listed the html code below . Can anyone tell me how I can add the onFocus element using js ? thanks
<input name="associate" id="associate" type="text" size="30" autocomplete="OFF"
onkeyup="return associatejs() "
onclick="closeassociate()"
/>
something like onFocus=Blur() inside the input
Hope this makes sense,