sabecs
asked on
JavaScript function required for form onfocus and onblur
I have a form as below, onfocus and onblur where previously working but not anymore.
Can anyone provide a JavaScript function to do the same thing and should I try loading at the bottom of the page.
Thanks in advance
Can anyone provide a JavaScript function to do the same thing and should I try loading at the bottom of the page.
Thanks in advance
<form action="members-search" method="GET">
<br />
<div id="get_my_location" class="ui-widget"><label for="suburb">Where do you need a Service Professional?</label><br />
<input type="text" value="Enter Post Code or Suburb" name="suburb" id="suburb"
onfocus="if(this.value == 'Enter Post Code or Suburb'){ this.value = ''; }"
onblur="if(this.value == ''){ this.value = 'Enter Post Code or Suburb'; }">
<br />
<input id="set_suburb" type="submit" value="Get Started" /></div><br />
</form>
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER