Welcome Guest, Not a member yet? Register   Sign In
Search Criteria Ignored, Only Redirects to Else Statement
#10

(This post was last modified: 06-13-2019, 01:18 PM by jreklund.)

You haven't provided us with any code for your view (where the search submit button are), so I can't tell you why it ain't working. If you would be so kind to post it and a form that's working.

If a type="submit" dosen't have a name="" field it will not show up. If you provided it with name="submit" it will populate $this->input->post('submit') with whatever your value="" are.

eg.
Code:
<input type="submit" name="submit" value="Submit!" />

Will give you: Submit!

Code:
<input type="submit" value="Submit!" />

Will give you: null (not a string, just null)

And therefor return false in an if statement. So I guess you don't have a name="" on that particular button, but everything else.

You need to close your your parenthesis.
Code:
if ($this->input->method() === 'post')
Reply


Messages In This Thread
RE: Search Criteria Ignored, Only Redirects to Else Statement - by jreklund - 06-13-2019, 01:17 PM



Theme © iAndrew 2016 - Forum software by © MyBB