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.

Simple search results path issue

June 21, 2012 6:49pm

Subscribe [3]
  • #1 / Jun 21, 2012 6:49pm

    qaswa

    9 posts

    I’m probably missing something silly, but I can’t resolve this issue and can’t find anything to help in the docs or forums. I’m trying a vanilla implementation of the search module and getting this error when I search:

    A PHP Error was encountered
    Severity: Notice
    Message: Undefined index: result_page
    Filename: search/mod.search.php
    Line Number: 84

    I’ve tried a number of different variations on defining the path to results page (with group, without group, full path, etc.). I have also tried to define the path from both the search instantiation and the channel prefs. I’ve verified that all the markup is valid. I have a flat file structure (everything is in one group called “stories”). Here is my search code:

    {exp:search:simple_form channel="stories" search_in="everywhere" result_page="stories/results" no_result_page="stories/results_none" results="5"}
      <input type="text" name="keywords" id="keywords" value="" maxlength="100" class="input-small search-query">
      <input type="submit" class="btn" value="submit" class="submit">
    {/exp:search:simple_form}

    Here’s the meat of my results page:

    {exp:search:search_results}
      <div class="well result">
        <h2><a href="http://{auto_path}">{title}</a></h2>
    <p>  </div><br />
    {/exp:search:search_results}

    When I hit the results page on its own, I get “Your search did not return any results.”

    Thanks in advance for any insight!

    -Ammon

  • #2 / Jun 21, 2012 7:11pm

    Stephen Callender

    148 posts

    Hmm. Can you show us the full template code (or just one of them) where your search form is? It may be something around your search:simple_form causing a problem.

  • #3 / Jun 21, 2012 8:01pm

    qaswa

    9 posts

    Stephen - you were right! I was posting the full code and realized I had a <form> wrapping the search module definition. Works now. Thanks! -Ammon

  • #4 / Jun 21, 2012 9:10pm

    Shane Eckert

    7174 posts

    Hey qaswa,

    I am glad that Stephen was able to help you pinpoint that issue.

    If you need anything else, just let me know!!

    -Shane

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

ExpressionEngine News!

#eecms, #events, #releases