Welcome Guest, Not a member yet? Register   Sign In
Validation issue

I am new to this forum so I would like to say: "Codeigniter is the best!".

Now to get to my problem.
I have a form, validation rules like required, xss_clean, etc are added. Everithing works according to the book. No problem here
My issue is that i want my input fields to have a default value like: [email protected] (for the email field).
in the input field i have this
<input name="sEmail" type="text" id="sEmail" title="Email address" value="<?php echo $this->validation->sEmail;?>"/>

This will return the entered value for this field if the form has errors.
But i need to add a value to that field befor that field is submited.

I hope i was clear about my problem, I've been looking into the manual but nothing about default values and validations Sad as far as i remember.

Any help ideeas are welcomed.

Thank you


I think the solution is in the link.

Thank you for you fast reply that helped with my issue.
And yes i do believe that this should be one of CI core functionality.
Thank you, very much

Glad you got it working.

Theme © iAndrew 2016 - Forum software by © MyBB