And if you don't insist of doing it with Prototype, you can do some really cool usability form enhancements with JQuery.
I have a register form with three fields.
my requirement is...
when i focus("onFocus") on name "text_field" a small message should display as " Name required".
When i move from that text_field("onBlur") it has to validation. That is "empty or Not".
I have three options.
1) Livevalidation plugin.