Welcome Guest, Not a member yet? Register   Sign In
From form to URI
#1

[eluser]Unknown[/eluser]
Hello, i have a form with input, i want to put the input value in the uri
e.g if user enters "12345" to input and submit the form, the URI becomes controller/method/12345

should i use HTTP header "Location" ?
#2

[eluser]davidbehler[/eluser]
You can set the form to use method 'get' but that would result in controller/method/&input_name=12345 I guess.
Easiest way to do this is propably sending the form to controller/method, then check if the submitted ID is valid and then redirect to controller/method/ID using the CI redirect function.




Theme © iAndrew 2016 - Forum software by © MyBB