Welcome Guest, Not a member yet? Register   Sign In
How to pass data from a view to a controller?
#3

[eluser]theciman[/eluser]
The website gives users the ability to change certain attributes within a database. After they login, they can list certain values within the database which I provide through a query. The values are presented in input_forms and dropdown menus which a user has the ability to change. Once he makes the changes and clicks the submit button, I do a $this->input->post call in the controller for each of the form_inputs and dropdown forms to see what was changed and then update the database accordingly. My issue is I need access to the row ID which was queried in the view and which needs to be returned to the controller so it knows what table row to update. I want to put the row id in a hidden form so the user does not have access to it but yet I need it so I know what table row to update. If I put the id in a input_form and then use the post method I have access to it but if I use a hidden form I don't. I need away to get the id which in the view over to the controller. If there is another way fine but I am not sure how to do this.

Any help would be great.


Messages In This Thread
How to pass data from a view to a controller? - by El Forum - 02-12-2010, 10:17 AM
How to pass data from a view to a controller? - by El Forum - 02-12-2010, 10:20 AM
How to pass data from a view to a controller? - by El Forum - 02-12-2010, 10:37 AM
How to pass data from a view to a controller? - by El Forum - 02-12-2010, 11:46 AM
How to pass data from a view to a controller? - by El Forum - 02-12-2010, 11:52 AM
How to pass data from a view to a controller? - by El Forum - 02-12-2010, 12:09 PM
How to pass data from a view to a controller? - by El Forum - 02-15-2010, 11:46 AM
How to pass data from a view to a controller? - by El Forum - 02-15-2010, 11:59 AM
How to pass data from a view to a controller? - by El Forum - 02-15-2010, 12:22 PM
How to pass data from a view to a controller? - by El Forum - 02-15-2010, 12:35 PM
How to pass data from a view to a controller? - by El Forum - 02-15-2010, 12:37 PM
How to pass data from a view to a controller? - by El Forum - 02-15-2010, 01:05 PM
How to pass data from a view to a controller? - by El Forum - 02-15-2010, 01:24 PM
How to pass data from a view to a controller? - by El Forum - 02-15-2010, 01:34 PM
How to pass data from a view to a controller? - by El Forum - 02-15-2010, 01:36 PM



Theme © iAndrew 2016 - Forum software by © MyBB