Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Daniel 10 posts 30 karma points
    Jan 10, 2011 @ 13:20
    Daniel
    0

    Logging search terms

    Hi,

    I believe that XSLT Search does not offer a method of logging search terms that users have entered. I was wondering if anyone has added this functionality to XSLT Search or if they can suggest how it should be done. Perhaps using some C# or XSLT to store each search in the Umbraco database or in a log file.

    Thanks

    -Daniel.

  • Douglas Robar 3570 posts 4711 karma points MVP ∞ admin c-trib
    Jan 10, 2011 @ 13:29
    Douglas Robar
    0

    The easy way would be to add the search page to Google Analytics to track search terms.

    Otherwise, add a C# function to the .cs file in the app_data folder that will connect to a database (either the umbraco database or your own) and insert a record for each search performed. You would then add a call to that function in the XSLTsearch.xslt file when search results are displayed. 

    cheers,
    doug.

Please Sign in or register to post replies

Write your reply to:

Draft