Repository: incubator-guacamole-website Updated Branches: refs/heads/asf-site 14c8cfaa4 -> 8679dd305
http://git-wip-us.apache.org/repos/asf/incubator-guacamole-website/blob/8679dd30/content/releases/0.9.8/index.html ---------------------------------------------------------------------- diff --git a/content/releases/0.9.8/index.html b/content/releases/0.9.8/index.html index 2e0cb8d..a5d5297 100644 --- a/content/releases/0.9.8/index.html +++ b/content/releases/0.9.8/index.html @@ -108,28 +108,34 @@ <ul> <li><a href="http://downloads.sourceforge.net/project/guacamole/current/extensions/guacamole-auth-jdbc-0.9.8.tar.gz" - onclick="ga('send', 'event', { - eventCategory : 'Download', - eventAction : 'click', - eventLabel : 'guacamole-auth-jdbc-0.9.8.tar.gz', - transport : 'beacon' - })">Database Authentication</a></li> + onclick="trackDownload( + 'click', + 'guacamole-auth-jdbc-0.9.8.tar.gz' + )" + oncontextmenu="trackDownload( + 'menu', + 'guacamole-auth-jdbc-0.9.8.tar.gz' + )">Database Authentication</a></li> <li><a href="http://downloads.sourceforge.net/project/guacamole/current/extensions/guacamole-auth-ldap-0.9.8.tar.gz" - onclick="ga('send', 'event', { - eventCategory : 'Download', - eventAction : 'click', - eventLabel : 'guacamole-auth-ldap-0.9.8.tar.gz', - transport : 'beacon' - })">LDAP Authentication</a></li> + onclick="trackDownload( + 'click', + 'guacamole-auth-ldap-0.9.8.tar.gz' + )" + oncontextmenu="trackDownload( + 'menu', + 'guacamole-auth-ldap-0.9.8.tar.gz' + )">LDAP Authentication</a></li> <li><a href="http://downloads.sourceforge.net/project/guacamole/current/extensions/guacamole-auth-noauth-0.9.8.tar.gz" - onclick="ga('send', 'event', { - eventCategory : 'Download', - eventAction : 'click', - eventLabel : 'guacamole-auth-noauth-0.9.8.tar.gz', - transport : 'beacon' - })">NoAuth (Disabled) Authentication</a></li> + onclick="trackDownload( + 'click', + 'guacamole-auth-noauth-0.9.8.tar.gz' + )" + oncontextmenu="trackDownload( + 'menu', + 'guacamole-auth-noauth-0.9.8.tar.gz' + )">NoAuth (Disabled) Authentication</a></li> </ul> @@ -143,12 +149,14 @@ <ul> <li><a href="http://downloads.sourceforge.net/project/guacamole/current/binary/guacamole-0.9.8.war" - onclick="ga('send', 'event', { - eventCategory : 'Download', - eventAction : 'click', - eventLabel : 'guacamole-0.9.8.war', - transport : 'beacon' - })">guacamole-0.9.8.war</a></li> + onclick="trackDownload( + 'click', + 'guacamole-0.9.8.war' + )" + oncontextmenu="trackDownload( + 'menu', + 'guacamole-0.9.8.war' + )">guacamole-0.9.8.war</a></li> </ul> @@ -162,20 +170,24 @@ <ul> <li><a href="http://downloads.sourceforge.net/project/guacamole/current/source/guacamole-client-0.9.8.tar.gz" - onclick="ga('send', 'event', { - eventCategory : 'Download', - eventAction : 'click', - eventLabel : 'guacamole-client-0.9.8.tar.gz', - transport : 'beacon' - })">guacamole-client-0.9.8.tar.gz</a></li> + onclick="trackDownload( + 'click', + 'guacamole-client-0.9.8.tar.gz' + )" + oncontextmenu="trackDownload( + 'menu', + 'guacamole-client-0.9.8.tar.gz' + )">guacamole-client-0.9.8.tar.gz</a></li> <li><a href="http://downloads.sourceforge.net/project/guacamole/current/source/guacamole-server-0.9.8.tar.gz" - onclick="ga('send', 'event', { - eventCategory : 'Download', - eventAction : 'click', - eventLabel : 'guacamole-server-0.9.8.tar.gz', - transport : 'beacon' - })">guacamole-server-0.9.8.tar.gz</a></li> + onclick="trackDownload( + 'click', + 'guacamole-server-0.9.8.tar.gz' + )" + oncontextmenu="trackDownload( + 'menu', + 'guacamole-server-0.9.8.tar.gz' + )">guacamole-server-0.9.8.tar.gz</a></li> </ul> @@ -362,5 +374,32 @@ ga('send', 'pageview'); </script> + <!-- Download tracking helper function --> + <script type="text/javascript"> + + /** + * Signals Google Analytics that a file is being downloaded (or, at + * least, we expect that it is). Note that it is not possible to + * determine this with 100% certainty without grepping server logs, + * but this should still at least help gauge interest/usage. + * + * @param {String} action + * A human-readable string describing the user event which + * occurred to initiate the download. + * + * @param {String} filename + * The filename of the file being downloaded. + */ + function trackDownload(action, filename) { + ga('send', 'event', { + eventCategory : 'Download', + eventAction : action, + eventLabel : filename, + transport : 'beacon' + }); + } + + </script> + </body> </html> http://git-wip-us.apache.org/repos/asf/incubator-guacamole-website/blob/8679dd30/content/releases/0.9.9/index.html ---------------------------------------------------------------------- diff --git a/content/releases/0.9.9/index.html b/content/releases/0.9.9/index.html index 163a3a2..1d3acdc 100644 --- a/content/releases/0.9.9/index.html +++ b/content/releases/0.9.9/index.html @@ -108,28 +108,34 @@ <ul> <li><a href="http://downloads.sourceforge.net/project/guacamole/current/extensions/guacamole-auth-jdbc-0.9.9.tar.gz" - onclick="ga('send', 'event', { - eventCategory : 'Download', - eventAction : 'click', - eventLabel : 'guacamole-auth-jdbc-0.9.9.tar.gz', - transport : 'beacon' - })">Database Authentication</a></li> + onclick="trackDownload( + 'click', + 'guacamole-auth-jdbc-0.9.9.tar.gz' + )" + oncontextmenu="trackDownload( + 'menu', + 'guacamole-auth-jdbc-0.9.9.tar.gz' + )">Database Authentication</a></li> <li><a href="http://downloads.sourceforge.net/project/guacamole/current/extensions/guacamole-auth-ldap-0.9.9.tar.gz" - onclick="ga('send', 'event', { - eventCategory : 'Download', - eventAction : 'click', - eventLabel : 'guacamole-auth-ldap-0.9.9.tar.gz', - transport : 'beacon' - })">LDAP Authentication</a></li> + onclick="trackDownload( + 'click', + 'guacamole-auth-ldap-0.9.9.tar.gz' + )" + oncontextmenu="trackDownload( + 'menu', + 'guacamole-auth-ldap-0.9.9.tar.gz' + )">LDAP Authentication</a></li> <li><a href="http://downloads.sourceforge.net/project/guacamole/current/extensions/guacamole-auth-noauth-0.9.9.tar.gz" - onclick="ga('send', 'event', { - eventCategory : 'Download', - eventAction : 'click', - eventLabel : 'guacamole-auth-noauth-0.9.9.tar.gz', - transport : 'beacon' - })">NoAuth (Disabled) Authentication</a></li> + onclick="trackDownload( + 'click', + 'guacamole-auth-noauth-0.9.9.tar.gz' + )" + oncontextmenu="trackDownload( + 'menu', + 'guacamole-auth-noauth-0.9.9.tar.gz' + )">NoAuth (Disabled) Authentication</a></li> </ul> @@ -143,12 +149,14 @@ <ul> <li><a href="http://downloads.sourceforge.net/project/guacamole/current/binary/guacamole-0.9.9.war" - onclick="ga('send', 'event', { - eventCategory : 'Download', - eventAction : 'click', - eventLabel : 'guacamole-0.9.9.war', - transport : 'beacon' - })">guacamole-0.9.9.war</a></li> + onclick="trackDownload( + 'click', + 'guacamole-0.9.9.war' + )" + oncontextmenu="trackDownload( + 'menu', + 'guacamole-0.9.9.war' + )">guacamole-0.9.9.war</a></li> </ul> @@ -162,20 +170,24 @@ <ul> <li><a href="http://downloads.sourceforge.net/project/guacamole/current/source/guacamole-client-0.9.9.tar.gz" - onclick="ga('send', 'event', { - eventCategory : 'Download', - eventAction : 'click', - eventLabel : 'guacamole-client-0.9.9.tar.gz', - transport : 'beacon' - })">guacamole-client-0.9.9.tar.gz</a></li> + onclick="trackDownload( + 'click', + 'guacamole-client-0.9.9.tar.gz' + )" + oncontextmenu="trackDownload( + 'menu', + 'guacamole-client-0.9.9.tar.gz' + )">guacamole-client-0.9.9.tar.gz</a></li> <li><a href="http://downloads.sourceforge.net/project/guacamole/current/source/guacamole-server-0.9.9.tar.gz" - onclick="ga('send', 'event', { - eventCategory : 'Download', - eventAction : 'click', - eventLabel : 'guacamole-server-0.9.9.tar.gz', - transport : 'beacon' - })">guacamole-server-0.9.9.tar.gz</a></li> + onclick="trackDownload( + 'click', + 'guacamole-server-0.9.9.tar.gz' + )" + oncontextmenu="trackDownload( + 'menu', + 'guacamole-server-0.9.9.tar.gz' + )">guacamole-server-0.9.9.tar.gz</a></li> </ul> @@ -408,5 +420,32 @@ interface layout and behavior, and improved support for Microsoft Edge.</p> ga('send', 'pageview'); </script> + <!-- Download tracking helper function --> + <script type="text/javascript"> + + /** + * Signals Google Analytics that a file is being downloaded (or, at + * least, we expect that it is). Note that it is not possible to + * determine this with 100% certainty without grepping server logs, + * but this should still at least help gauge interest/usage. + * + * @param {String} action + * A human-readable string describing the user event which + * occurred to initiate the download. + * + * @param {String} filename + * The filename of the file being downloaded. + */ + function trackDownload(action, filename) { + ga('send', 'event', { + eventCategory : 'Download', + eventAction : action, + eventLabel : filename, + transport : 'beacon' + }); + } + + </script> + </body> </html> http://git-wip-us.apache.org/repos/asf/incubator-guacamole-website/blob/8679dd30/content/releases/index.html ---------------------------------------------------------------------- diff --git a/content/releases/index.html b/content/releases/index.html index 46ef9fe..74fbc28 100644 --- a/content/releases/index.html +++ b/content/releases/index.html @@ -282,5 +282,32 @@ ga('send', 'pageview'); </script> + <!-- Download tracking helper function --> + <script type="text/javascript"> + + /** + * Signals Google Analytics that a file is being downloaded (or, at + * least, we expect that it is). Note that it is not possible to + * determine this with 100% certainty without grepping server logs, + * but this should still at least help gauge interest/usage. + * + * @param {String} action + * A human-readable string describing the user event which + * occurred to initiate the download. + * + * @param {String} filename + * The filename of the file being downloaded. + */ + function trackDownload(action, filename) { + ga('send', 'event', { + eventCategory : 'Download', + eventAction : action, + eventLabel : filename, + transport : 'beacon' + }); + } + + </script> + </body> </html> http://git-wip-us.apache.org/repos/asf/incubator-guacamole-website/blob/8679dd30/content/support/index.html ---------------------------------------------------------------------- diff --git a/content/support/index.html b/content/support/index.html index c6f281b..e3c9dd9 100644 --- a/content/support/index.html +++ b/content/support/index.html @@ -266,5 +266,32 @@ Guacamole changes back to the project and community.</p> ga('send', 'pageview'); </script> + <!-- Download tracking helper function --> + <script type="text/javascript"> + + /** + * Signals Google Analytics that a file is being downloaded (or, at + * least, we expect that it is). Note that it is not possible to + * determine this with 100% certainty without grepping server logs, + * but this should still at least help gauge interest/usage. + * + * @param {String} action + * A human-readable string describing the user event which + * occurred to initiate the download. + * + * @param {String} filename + * The filename of the file being downloaded. + */ + function trackDownload(action, filename) { + ga('send', 'event', { + eventCategory : 'Download', + eventAction : action, + eventLabel : filename, + transport : 'beacon' + }); + } + + </script> + </body> </html>
