Welcome Guest, Not a member yet? Register   Sign In
Need help with Styling form Validation

Hi - I have uncovered a curious situation. I can easily style the validation_errors() this way:

echo "<span class='validation'>".validation_errors()."</span>";

However, if I attempt to style form_error() inthe same way,

echo "<span class='validation'>". form_error('Email'). "</span>";

the styling is ignored. In fact the span does not even wrap around the error mssage ! The rendered source code ends up looking like this:

<label for="Email">Email</label>
<span class="validation"></span>
<p>The Email field must contain a valid email address.</p>
&lt;input id="Email" type="text" size="45" value="[email protected]" name="Email"&gt;

I must be doing something really stupid - but I can't see it -

Many Many Thanks for any ideas !

Cheers !

Theme © iAndrew 2016 - Forum software by © MyBB