Integration manual


Installation

  • Stop the server
  • Download jar from plugin and add it (ametys-plugin-web-analytics-1.1.x.jar) in the WEB-INF/lib directory of your application. Ametys
  • Restart the server

Integration into the graphic charter

To insert the Piwik code into your pages, import the style sheet XSLT into your graphic charter (file in web\skins\[NOMDELASKIN]\stylesheets\head.xsl)

<xsl:import href="plugin:web-analytics://stylesheets/piwik.xsl" /> 

Then use the template piwik in the <head>

<html> 
<head> 
       [...] 
       <xsl:call-template name="piwik"/> 
</head> 

    <body>...</body> 
</html> 

Advanced settings: statistics on searched keywords

Piwik provides statistics on the most searched keywords.

Since version 1.1.0 of plugin web-analytics, Ametys supports this feature by sending the keywords searched for through the "texfield" search field to the Piwik server. This search field is the "Keywords" search field used by default in all Ametys search engines.

If you need to track another search field, use the "piwik" template, specifying the search field(s) to be tracked as below:

<xsl:call-template name="piwik"> 
<xsl:with-param name="keywordFields"> 
<fields> 
<field name="textfield"/> 
<field name="keywords"/> 
</fields> 
</xsl:with-param> 
</xsl:call-template> 

 

 

Back to top

Web analytics