Project

General

Profile

« Previous | Next » 

Revision 5702

add download count for data entities (online distribution)

View differences:

eml-distribution.xsl
140 140
          <xsl:attribute name="target">_blank</xsl:attribute>
141 141
          <xsl:value-of select="."/>
142 142
        </a>
143
        <!-- stats for hosted documents loaded with ajax call -->
144
        <xsl:if test="starts-with($URL,'ecogrid')">
145
			<xsl:variable name="URL1" select="substring-after($URL, 'ecogrid://')"/>
146
			<xsl:variable name="docID" select="substring-after($URL1, '/')"/>
147
			<xsl:variable name="divID" select="replace($docID, '.', '_')"/>
148
			<span>
149
          		<xsl:attribute name="id">
150
          			<xsl:value-of select="$divID" />
151
          		</xsl:attribute>
152
			</span>
153
			<script language="JavaScript">
154
				if (window.loadStats) {
155
					loadStats('<xsl:value-of select="$divID" />', '<xsl:value-of select="$docID" />', '<xsl:value-of select="$contextURL" />/metacat');
156
				}
157
			</script>
158
		</xsl:if>			
143 159
       </td>
144 160
    </tr>
145 161
  </xsl:template>

Also available in: Unified diff