Welcome Guest, Not a member yet? Register   Sign In
Send variables from a view to a controller
#1

[eluser]Paul Hernández[/eluser]
May be a stupid question but how can I send values from a view to a controller without using post values, I mean, I usually use Form_open(myController) and in the controller I read the submited values with $this->input->post[fieldName] but what happend if I want to send other information which is not in an input field.

Thanks

Paul
#2

[eluser]WanWizard[/eluser]
A view isn't meant for that, a view has a display (=output) purpose, you shouldn't do any processing in a view.

To feed information back from a page, you use a form (= post variables), URI segments ( p.e. http://www.example.com/controller/method...rm2/valueB ), or javascript code (AJAX, which basically is a post as well).




Theme © iAndrew 2016 - Forum software by © MyBB