We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 1511
    • 144 Posts
    I’ve found the cause for this.

    Not all variables are set since there are include_once directives in PHP.

    Check lines between (approx) 246-265. All you gotta do there is change all include_once directives to include (4 times). The final result looks like this
    /* -------------
      End configure
     -------------- */
    
    // Set Snippet Paths
    $snipPath = $modx->config['base_path'] . "assets/snippets/";
    include $snipPath."AjaxSearch/includes/AjaxSearch.inc.php";
    include $snipPath."AjaxSearch/includes/templates.inc.php";
    
    #include default language file
    include($snipPath."AjaxSearch/lang/english.inc.php");
    
    #include other language file if set.
    $as_language = isset($language) ? $language : $modx->config['manager_language'];
    if($as_language!="english" && $as_language != '') {
        if(file_exists($snipPath ."AjaxSearch/lang/".$as_language.".inc.php"))
            include $snipPath ."AjaxSearch/lang/".$as_language.".inc.php";
    }
    
      • 22563
      • 63 Posts
      ...change all include_once directives to include (4 times). ...
      -> blank page

      Need some template advice for the AjaxSearch template (templates.inc.php):
      How do I get the same result as on the author’s homepage (http://www.muddydogpaws.com)?

      A menu-header "Search" above the search form on the side bar, which "disappears" with the search if browsing to the "more results page".

      I tried to add this to
      //Form Template
      	'form' => '
               <h3>Search</3>
      


      But with this the <h3>Search</3> appears on the "more results page", too.
        • 1511
        • 144 Posts
        Maybe he has a different template for the search results page.
          • 15987
          • 786 Posts
          No, I did not change the template for my site.

          I have a chunk in the sidebar with something like this:

          <h3>Search</h3>
          [!AjaxSearch? &asdf=`sc`!]
          
            • 22563
            • 63 Posts
            Hi!

            could you please explain in detail?
            The <h3>Search</h3> still appears over here...
            embarrassed
              • 15987
              • 786 Posts
              ok, in my sidebar I have a chunk called sideSearch. in that chunk I have the following :

              <h3>Search</h3>
              [!AjaxSearch? &asdf=`sc`!]
              


              then on my results page in the content I have the following:

              <h1>Search Results</h1>
              [!AjaxSearch? &asdf=`sc`!]


              hope that helps
                • 22563
                • 63 Posts
                embarrassed ...i am afraid it does not... sorry for my n00bness...

                I’ve also to call the snipped cached on my results page to get any results.
                  • 15987
                  • 786 Posts
                  did you change the template file?
                    • 22563
                    • 63 Posts
                    not the ajaxsearch template
                      • 23802
                      • 65 Posts
                      hey guys, i tried to find that info but i failed so for.

                      I use different language for my modx site and ajax search seem not to respond to that language...

                      Is there any way to reprogram search engine by my self so it would support non latin languages type...

                      seems 0.96R1 responds to other languages, cheers for that

                      thanks

                      This discussion is closed to further replies. Keep calm and carry on.