Custom errors in Form Validation (basic) |
[eluser]Stu Green[/eluser]
Hey all Just thought I'd share some code that I've been working on. This is a really simple solution to a problem that I've had with the new Form Validation class. You can set custom error messages with it. Code below, also in my blog post: http://www.haloweb.co.uk/blog/2009/03/co...ion-class/ If anyone wants to build on it, feel free. Thanks Code: <?php if (!defined('BASEPATH')) exit('No direct script access allowed');
[eluser]pistolPete[/eluser]
Since MY_Form_validation is just a subclass of Form_validation, you could use: Code: function set_error($error = '') |
Welcome Guest, Not a member yet? Register Sign In |