views: remove old matomo analytics code.
This is no longer used and shouldn't have been hardcoded anyway.
This commit is contained in:
@@ -60,18 +60,6 @@
|
||||
window.Danbooru.notice = Danbooru.Utility.notice;
|
||||
window.Danbooru.error = Danbooru.Utility.error;
|
||||
|
||||
window._paq = window._paq || [];
|
||||
<% if CurrentUser.is_member? && !CurrentUser.opt_out_tracking? %>
|
||||
window._paq.push(["setUserId", '<%= CurrentUser.id %>']);
|
||||
<% end %>
|
||||
window._paq.push(["setDomains", "*.donmai.us"]);
|
||||
<% if !CurrentUser.opt_out_tracking? %>
|
||||
window._paq.push(["setCustomVariable", 1, "level", <%= CurrentUser.level %>, "visit"]);
|
||||
window._paq.push(["setCustomVariable", 2, "age", <%= ((Time.now - CurrentUser.created_at) / 1.year).to_i %>, "visit"]);
|
||||
window._paq.push(["setCustomVariable", 3, "postUpdateCount", <%= CurrentUser.post_update_count.to_i / 100 %>, "visit"]);
|
||||
window._paq.push(["setCustomVariable", 4, "favoriteCount", <%= CurrentUser.favorite_count.to_i / 100 %>, "visit"]);
|
||||
<% end %>
|
||||
|
||||
window.addthis_config = { ui_click: true };
|
||||
</script>
|
||||
<%= tag.meta name: "twitter:title", content: page_title %>
|
||||
|
||||
@@ -189,12 +189,4 @@
|
||||
<%= tag.meta name: "og:site", content: Danbooru.config.app_name %>
|
||||
|
||||
<%= auto_discovery_link_tag(:atom, comments_url(:atom, search: { post_id: @post.id }), title: "Comments for post ##{@post.id}") %>
|
||||
|
||||
<script>
|
||||
window._paq = window._paq || [];
|
||||
window._paq.push(["setCustomVariable", 1, "rating", '<%= j @post.rating %>', "page"]);
|
||||
window._paq.push(["setCustomVariable", 2, "fileSize", <%= @post.file_size.to_i / 100.kilobytes %>, "page"]);
|
||||
window._paq.push(["setCustomVariable", 3, "sourceDomain", '<%= j @post.source_domain %>', "page"]);
|
||||
window._paq.push(["setCustomVariable", 3, "blocked", <%= @post.levelblocked? %>, "page"]);
|
||||
</script>
|
||||
<% end %>
|
||||
|
||||
@@ -8,14 +8,3 @@
|
||||
<%= stripe_button("Upgrade Gold to Platinum", UserUpgrade.upgrade_price, user) %>
|
||||
<% end %>
|
||||
</div>
|
||||
|
||||
<% content_for(:html_header) do %>
|
||||
<script>
|
||||
$(function() {
|
||||
$(".stripe").submit(function(e) {
|
||||
window._paq = window._paq || [];
|
||||
window._paq.push(['trackEvent', 'accounts', 'clickedAccountUpgrade']);
|
||||
});
|
||||
});
|
||||
</script>
|
||||
<% end %>
|
||||
|
||||
@@ -119,12 +119,3 @@
|
||||
<% end %>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<% content_for(:html_header) do %>
|
||||
<script>
|
||||
$(function() {
|
||||
window._paq = window._paq || [];
|
||||
window._paq.push(['trackEvent', 'accounts', 'viewAccountUpgrade']);
|
||||
});
|
||||
</script>
|
||||
<% end %>
|
||||
|
||||
Reference in New Issue
Block a user