ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

Advanced Search Form Parameters

February 18, 2011 3:11pm

Subscribe [3]
  • #1 / Feb 18, 2011 3:11pm

    Lee Powell

    88 posts

    Hi

    Is the advanced search form able to use the same parameters as the simple search form i.e. ‘search_in’ & ‘where’?

    I’m trying to create an advanced form that searches in ‘all’ by default, but the user can use a checkbox to override the form to search for ‘any’ within the ‘where’ parameter… but it’s not quite working properly.

    Any help would be appreciated.

  • #2 / Feb 18, 2011 3:58pm

    Lee Powell

    88 posts

    Bit of digging around in the code - should have checked first really. Can use the simple form parameters (although can’t see that documented). But there is no where in the code base that EE checks for $_POST vars to override the constructed meta value produced by EE and added as a hidden input.

    In fact - even is you remove the ‘where’ from the parameters, and add it to the form as per the documentation here: http://ellislab.com/expressionengine/user-guide/modules/search/advanced.html, it fails to work. As there is no checking on the $_POST data being submitted by the form.

  • #3 / Feb 18, 2011 5:21pm

    narration

    773 posts

    Lee, we recently worked pretty thoroughly on the problems as you are seeing, and you can find some corrective patches in this thread, with hints for any others needed, starting here: Search Issues and Fixes.

    As you’ll see, there’s also a bug report.

    Hoping this will get you on the air - you’re right, code is presently missing for Advanced Search forms to work. Also, you are correct that the Simple form tag parameters do continue to work on Advanced. Whether form items over-ride will depend on how Ellis finally arranges things. I think they should.

    Regards,
    Clive

  • #4 / Feb 19, 2011 4:40am

    Lee Powell

    88 posts

    Thanks for this - although I know modifying the core will get it working, I’m inclined to wait for a fix to come from EE.

  • #5 / Feb 20, 2011 3:45pm

    Greg Salt

    3988 posts

    Hi Lee,

    Now that Clive has pointed you at the information related to this issue I’m going to go ahead and close this thread. Please open a related one if required.

    Cheers

    Greg

    @narration, thanks very much for your help.

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases