![]() |
validate upload in edit module and how show the errors about the uploading data - 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: validate upload in edit module and how show the errors about the uploading data (/showthread.php?tid=15285) |
validate upload in edit module and how show the errors about the uploading data - El Forum - 01-30-2009 [eluser]Asinox[/eluser] Hi, Please i need to know how show the error in editing data... for example, the url : http://domain/index.php/site/editing/3 If the form fields are empty the normal way is redirecting to the view with the form... but somebody hav a nice way to redirect to the view and show the errors?, i know that ill make something like that: redirect($this->uri->uri_string(),'location'), but i cant see the errors msg's. i need to know if there's nice way to do that. thanks u all validate upload in edit module and how show the errors about the uploading data - El Forum - 01-31-2009 [eluser]Crimp[/eluser] The Form_validation class does this. You use the function form_error('[name of field']) to display the individual error or validation_errors() to display all errors. The Form helper can be handy if there are a lot of forms to do. validate upload in edit module and how show the errors about the uploading data - El Forum - 01-31-2009 [eluser]Asinox[/eluser] hi, ok, maybe i said something wrong i know how validate form's, but my problem is when i want to validate form in editing mode, because the validation is running in the function where i save the new data, Example: Code: <form action="controller/insert_edited_data"> the funcion "insert_edited_data" update the data , but if i try to validate the data i don't know how go back to the "editing view" with the "ID" in the URL and show the msg's about validation. im sorry with my English... is more or less clear? Thanks. |