Multi upload file and validation form |
[eluser]loca[/eluser]
I have a form with multi file upload, each file field I have a button to choose a file. I use form validation but I have problem: Assume that I have some file fields in view file Code: <input name="file1" type="file" /> In my controller, to validate these file field I use structure of code as in Codeigniter User Guide following Code: $this->form_validation->set_rules('username', 'Username', 'callback_username_check'); when I select a file for "file1" and not select any file for "file2". In this time, I don't want to upload any file to my server if all field is required. But if use callback function. Each times I check for validate. "File1" will be uploaded to server.
[eluser]toopay[/eluser]
Validation must be done with inspect $_FILES array, not like text box validation.
[eluser]loca[/eluser]
How can I retain file entry if form validation is not successful?
[eluser]Unknown[/eluser]
can do it everyone but i will try this than i call but now we should do more activity Automated Forex Trading Software |
Welcome Guest, Not a member yet? Register Sign In |