Search code examples
javascriptgoogle-search-appliance

How does one notify a Google Search Appliance of a clicked link when displaying custom results?


I am performing a web request to a Google Search Appliance (GSA) and returning XML. I then parse that XML to create internal links to an EXTJS web application. My main question is, how do I tell the GSA which link was clicked from my custom results in order to not lose the click rank training? I'd hate to lose the GSA's ability to learn which results are relevant over time, but I must construct links from the XML returned by the GSA. I know I could display the results in an IFrame, but that is not possible given my requirements. I've looked through the documentation, but I haven't found any good leads yet. Any help on this matter will be greatly appreciated.


Solution

  • In order to get click tracking from a non-XSLT based search page, you need to do the following:

    1) Copy the clicklog.js or clicklog_compiled.js from the GSA and reference it within your page. (located at http:///*.js 2) You'll need to implement a reverse proxy for /click on your webserver and point it to http://

    It parses all of the anchor tags in the page so you don't have to do much beyond that. The ASR reports and captured by an attribute ctype as in

    Some details regarding the protocol: https://developers.google.com/search-appliance/documentation/614/xml_reference?hl=de-DE#ASRProtocol