Nice way of getting field values? |
[eluser]überfuzz[/eluser]
Is there a fancy pancy way of getting field values from a <form etc.. > in a viewer lets say form.php to a controller email.php. Or is it the old fashion way. I can't find any thing in the user_guide. Is it because there isn't anything or did I mess up the search? Code: $message = $_POST['firstname']. " says hello frendo!";
[eluser]daparky[/eluser]
If you are going to be inserting data i just do something like this:- Code: $values = $_POST; But for email, i think you have to do it the way your doing it.
[eluser]überfuzz[/eluser]
I guess this is the CI-way. Code: $this->input->post('name');
[eluser]wabu[/eluser]
If you name your form fields like "animal[name]" then "$this->input->post('animal')" gets you your complete animal. Combine it with something like the following for bonus points. ![]() http://www.krisjordan.com/2008/11/27/dyn...-stdclass/ |
Welcome Guest, Not a member yet? Register Sign In |