While your mark-up is invalid, I've got a solution that will work. It requires a little jQuery, but is flexible enough to meet your needs:
View fiddle
I've taken the liberty of fixing your HTML:
<label for="password">Password: </label>
<input type="password" class="help" id="password" name="password" maxlength="100" rel="help_password" />
<span id="help_password" class="message">...password message...</span>
To adhere to WCAG standards, your input field requires a correlating label tag. I've also added a rel attribute which the value should match an ID tag of the corresponding help message's ID attribute.
And with a tiny bit of jQuery:
$(document).ready(function(event) {
$('input.help').focus(function(event) {
$('#' + $(this).attr('rel')).show();
});
$('input.help').blur(function(event) {
$('#' + $(this).attr('rel')).hide();
});
});
You can auto-toggle the help message for any field that has the class "help" and a corresponding help message span tag.