>
diff --git a/themes/plugins.jquery.com/functions.php b/themes/plugins.jquery.com/functions.php
index ba57fdf4..e7bd8b15 100644
--- a/themes/plugins.jquery.com/functions.php
+++ b/themes/plugins.jquery.com/functions.php
@@ -1,5 +1,9 @@
post_parent ) ? $post->ID : $post->post_parent;
diff --git a/themes/plugins.jquery.com/js/download-tracker.js b/themes/plugins.jquery.com/js/download-tracker.js
new file mode 100644
index 00000000..649620c4
--- /dev/null
+++ b/themes/plugins.jquery.com/js/download-tracker.js
@@ -0,0 +1,17 @@
+$(document).ready(function() {
+ // Tracks clicks of the plugin download button
+ $("a.download").click(function(event) {
+ // Query parameter distinguishes click tracking request from normal page load
+ var clickTrackerURL = window.location + "?d=1";
+ var downloadURL = $(this).attr("href");
+
+ event.preventDefault();
+
+ $.ajax({
+ type: "HEAD",
+ url: clickTrackerURL
+ }).done(function() {
+ window.location = downloadURL;
+ });
+ });
+});
\ No newline at end of file