Query logs for custom search

eismarketing
Member

Hello,

We have a custom search filter set up for blogs.  Users can also enter a text string.  You can see how it works on this page:

https://www.earley.com/insights

What I've realized is that we have no access to understanding what search queries people enter into that text box. Is there a way to grab that information?

Thanks in advance,

Sharon

0 Upvotes
3 Replies 3
webdew
Top Contributor | Diamond Partner

Hi @eismarketing ,

If you want grab the information page load time, add form and after filling the form blog search/ Show page ETC.

Hope this helps!


If we were able to answer your query, kindly help the community by marking it as a solution.

Thanks and Regards. 

eismarketing
Member

Hello webdew,

I appreciate you taking the time to respond but I must admit I don't understand the answer!  

Sharon

0 Upvotes
miljkovicmisa
Contributor | Gold Partner

Hi @eismarketing , could you give some more info on what you need to accomplish?

i.e Your search has suggestions that are displayed as you type, so searching for "inf" would probably give a few results and it is meaningless to try and catch those strings.

A more meaningful approach would be to get the results only when someone goes to the results page after searching for something, so you can get the searched term from the dictionary with {{ request.query_dict.term|escape }} on your search results page.

Having the term you can do a lot of stuff, it just depends on what you want to accomplish.

One idea is to submit this result to a form, thus you can see all the submissions and compare them, see some analytics about the number of results or something else, it is difficult to suggest something without knowing what you would like to accomplish. Note, you will need to create a form with a property for the searched term.
Another idea is to use a custom event handler or something entirely else, like a workflow, etc.

So maybe you can elaborate a bit more on your request so we could help a bit more.

 

Some reference links here.
The dictionary from where to get the query_dict. (Search for query_dict)

Submitting data to a form using Forms API

 

Hope my answer helped you get a direction on where to go next, and maybe we'll be able to help you more after you share some more info about your approach.
If it did help you or you found it useful please mark it as a solution.

0 Upvotes