I am trying to pull in some Low Search results using AJAX. How can I pass a query to the result page without knowing the encrypted version of the keywords beforehand?
Here are some things I have tried.
I placed this on my result page in hopes that it would give me a URL I could use.
{exp:low_search:url
keywords="{segment_3}"
encode="no"
result_page="/my/result_page/"
}
The URL Tag spits out something like this:
http://mysite.com/?ACT=21&keywords=eyJjb2xsZWN0aW9uIjoiY3VzdG9tZXJfY29udHJhY3RzIiwibG9vc2VfZW5kcyI6InllcyIsInJlc3VsdF9wYWdlIjoiY29udHJhY3RzXC9zZWFyY2giLCJzZWFyY2hfbW9kZSI6ImFsbCIsImtleXdvcmRzIjoibHluIn0&result_page=%2Fmy%2Fresult_page%2F
I was hoping that it would not encode the keywords, and I would simply use a similar pattern for my AJAX call.
The URL it generates does not work as a stand-alone, therefor will not work for the AJAX call either. I have ruled out AJAX as being the problem, and come to the conclusion that I simply do not know how to pass keywords to Low Search without using the standard (non-js) form submit.
Any ideas?