I want to show example text in Email text-box so I used code:-
<input name="login[username]"
onfocus="if (this.value == 'john@gmail.com') {this.value = ''; }"
onblur="if (this.value == ''){this.value = 'john@gmail.com'; }"
value="john@gmail.com"
id="email"
type="text"
class="input-text required-entry"
title="<?php echo $this->__('Email Address') ?>" />
But when I clicked on submit button without entering value then it considers example text means "john@gmail.com"
as login id but it have to show error "required field.". Please help me.