We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 6696
    • 145 Posts
    Hi . . .

    I want to set up a search field and results page for my site. The modxhost template index page came with the installation so I am using that, but all that was there was the index and a search field that doesn’t function and no results page setup. How do I turn on the search field function and connect that to a results page? Is ther ea plug in I can get?

    thanks,
    Daniel
      • 28042 ☆ A M B ☆
      • 24,524 Posts
      AjaxSearch is a search snippet that is included with your MODx installation. It has lots of options; there is a documentation folder in the assets/snippets/ajaxSearch folder.
        Studying MODX in the desert - http://sottwell.com
        Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
        Join the Slack Community - http://modx.org
        • 6696
        • 145 Posts
        Is it fairly easy to implement or do I need to be fluent in ajax? Are there directions there?

        Daniel
          • 28042 ☆ A M B ☆
          • 24,524 Posts
          there is a documentation folder in the assets/snippets/ajaxSearch folder
          The AJAX part is optional, and it’s all done for you. All you have to do is make some decisions on how you want it to behave, and use the appropriate parameters in the snippet tags. As usual, style with CSS however you like.
            Studying MODX in the desert - http://sottwell.com
            Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
            Join the Slack Community - http://modx.org
            • 6696
            • 145 Posts
            Thanks . . . I do not know anything about Ajax. I hope it is workable for me. Thanks.

            Daniel
              • 28042 ☆ A M B ☆
              • 24,524 Posts
              Well, the AJAX part is built-in if you want it (snippet parameters can enable or disable it); all it does is do the search in the background and load in a list of search results without refreshing the page. Or, you can turn it off and have the user sent to a different page to view search results. Your choice. The documentation explains how it can be customized.
                Studying MODX in the desert - http://sottwell.com
                Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
                Join the Slack Community - http://modx.org
                • 6696
                • 145 Posts
                Thanks smiley How and where can I enable it or turn it off? Is that in the admin?

                Daniel