Forums

multiple input search (2 posts)

  1. donfriso
    Member
    Posted 9 months ago #

    Hey,

    I've been scratching my head the past days and getting quite desperate for a solution.

    I'm trying to build a search from 2 user inputs. This is the code I currezntly have:

    [Code moderated as per the Forum Rules. Please use the pastebin]

    However! This outputs:

    ?s=TYPED_IN_THE_INPUT_BOX&s=SELECTED_IN_DROPDOWN

    this ofcourse only searches for the last &s= in the url, so the input text is completely ignored...

    the following search url works however:

    ?s=TYPED_IN_THE_INPUT_BOX&SELECTED_IN_DROPDOWN

    So dropping the s= from the search url filters my posts perfectly.. But I can't find a way to build such a search query... I've been googeling and reading tutorials for days now, and can't seem to find anything.

    Any ideas? Thanks so much in advanced

  2. donfriso
    Member
    Posted 9 months ago #

    I've been thinking about using php and http_build_query, but then I have no idea how to get the user inputs into strings so I can use the http_build_query

Reply

You must log in to post.

About this Topic