By jhchnc on
Hi,
I want to load the array of form element error messages on an initial page render so that I can both populate a javascript object and so that i can convert my inputs into something like this:
<input type="text" rel="ERROR MSG HERE" class="CUSTOMCLASS" name="foo" value="bar" />
Currently the array of error messages is only available post submit, and only if an error occurs, AFAIK.
Can anyone suggest a snippet to include on a template such as "page-user-register.tpl.php" to accomplish this task? Is there a way to add the error message values in a form pre-processor such as "THEME_preprocess_user_register", which I'm already using???
Thanks in advance,
John