Welcome Guest, Not a member yet? Register   Sign In
Re-populating the form
#1

[eluser]Unknown[/eluser]
Hello.

I'm not using the Form Validation library because creating my own rules isn't very flexible.

For example, I can not pass more additional info to my callbacks:

function username_check($username, <$this->post->input('user_id')>) {}

Or I'm wrong? There is a way to do this?

My question is if I don't use Form Validation library set_value('field_name') work in my views, or I need to use $this->post->input('field_name') instead?

Thanks. Smile
#2

[eluser]ElShotte[/eluser]
Yeah you don't need to use the Form helper, if you don't, $this->post->input('field_name') won't be available, but you can achieve the same by doing let's say:

&lt;input type="text" name="field_name" value="&lt;?=$_POST['field_name']?&gt;" /&gt;

But if you have any dropdown menus it will get really tricky, you will have to write your own function and in my opinion you would simply be better of using the Form helper. What are you trying to check for in the username?




Theme © iAndrew 2016 - Forum software by © MyBB