Inject custom aggregators

By implementing a new theme extension point, you can apply different approaches to Active Site Analytics.

To do this, define implementation within the following theme extension point in the file plugin.xml:

com.ibm.portal.theme.plugin.ActiveSiteAnalyticsItems

If the theme extension loop is in place, it picks up the custom implementation of the extension point, and its output is added to the markup of the portal page. For details about the extension loop refer to the topic about Instrumenting a special theme for Active Site Analytics under the section about Including microformats of interest.

Alternatively, you can use the following JSP code to iterate over the page metadata and add the aggregator JavaScript include statement to the page:

<portal-logic:pageMetaData varname="pageMetaData">
   <portal-logic:urlFindInTheme file='js/${pageMetaData ["asa_aggregator"]}' 
         id="asa_aggregator_file"/>
   <c:if test="${asa_aggregator_file != null}">
      <script type="text/javascript" src='<%=asa_aggregator_file%>'></script>
   </c:if>
</portal-logic:pageMetaData>
The result of urlFindInTheme is cached. To clear the cache, restart the portal. Redeploying the theme is not sufficient to trigger a reevaluation of urlFindInTheme.


Parent

Analyzing user behavior by Active Site Analytics
How Active Site Analytics data is represented in the portal


Related tasks


Writing an aggregator for Active Site Analytics
Add an Active Site Analytics aggregator to a portal page
Instrument a theme for Active Site Analytics
Configure an aggregator at runtime
Aggregator JSP


Theme extension points

 


+

Search Tips   |   Advanced Search