Odd validation problem - 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: Odd validation problem (/showthread.php?tid=9808) |
Odd validation problem - El Forum - 07-09-2008 [eluser]Bramme[/eluser] Hey all, I've run into a spot of trouble using validation. Code: $data['form'] = array( This works perfectly fine. However, when I uncomment $data['form'] = array_merge($data['form'], $form); validation fails and throws errors against all the rules I set. I'm merging those two arrays so the values from my form disappear, seeing as I don't show a succes view (like suggested in the user guide) but simply the same form again... Odd validation problem - El Forum - 07-10-2008 [eluser]Bramme[/eluser] Nobody got a clue? Odd validation problem - El Forum - 07-10-2008 [eluser]xwero[/eluser] give this solution a try. Odd validation problem - El Forum - 07-10-2008 [eluser]Bramme[/eluser] Thanks, this throws an error though: Fatal error: Call to undefined method MY_Validation::_rules() in /var/www/vhosts/bramme.net/subdomains/mickm/httpdocs/systeem/applicatie/libraries/MY_Validation.php on line 5 edit: had to remove the ()... It's just _rules. But it doesn't work. edit2: it does work. I forgot I put the array with form attributes above the clear_values function, and I had to put it below. Thanks xwero! |