CodeIgniter Forums
Form submit error messages - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20)
+--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23)
+--- Thread: Form submit error messages (/showthread.php?tid=45538)



Form submit error messages - El Forum - 09-26-2011

[eluser]iceuser[/eluser]
I have a div where i echo the errors that show up in my form.

The thing is that in the view i do this:

Code:
<div class="submit_message">
  &lt;?php echo validation_errors(); ?&gt;
</div>

But when i go to the page without submitting it, i can see the error div being there without anything on it...


I want to hide it before the form is submitted, what is the best way to do this?

Thanks.