diff --git a/web/donate/donate.org b/web/donate/donate.org
index 0970631..0190524 100644
--- a/web/donate/donate.org
+++ b/web/donate/donate.org
@@ -1,231 +1,231 @@
# -*- html -*-
#+TITLE: GnuPG - Donate
#+STARTUP: showall
#+SETUPFILE: "../share/setup.inc"
#
# Note: Do not use relative links because this page is also used as a
# template from cgi-bin/. Using https://www.gnupg.org/... is
# fine as it is stripped before publishing.
#+BEGIN_HTML
Support GnuPG
To process your donation we need to collect some information.
This information is only used for the purpose of the donation
and no data will ever be send to any entity not directly
involved in the donation process. Not giving a name makes
the donation “anonymous” in that the name won’t be listed
on the public thank you page.
#+END_HTML
diff --git a/web/share/campaign/campaign.js b/web/share/campaign/campaign.js
index e06d356..a2ccfcc 100644
--- a/web/share/campaign/campaign.js
+++ b/web/share/campaign/campaign.js
@@ -1,70 +1,74 @@
/* For mobile devices in landscape orientation, the navbar is in the
way of the video. So hide it automatically then. */
$(document).ready(function() {
$(".navbar-fixed-top").autoHidingNavbar({
disableAutohide: true,
hideOffset: 20
});
check_autohide = function(event) {
let hide = (screen.width < 768) && (screen.height < screen.width);
$(".navbar-fixed-top").autoHidingNavbar("setDisableAutohide", !hide);
if (!hide) {
$(".navbar-fixed-top").autoHidingNavbar("show");
}
};
$(window).on('orientationchange', check_autohide);
check_autohide();
});
/* Random starting points for the testimonial carousel. */
$(document).ready(function() {
let nr_items_lg = 3 * $("#myCarousel div.item").length;
let nr_items_md = 2 * $("#myCarouselMedium div.item").length;
let nr_items_xs = 1 * $("#myCarouselSmall div.item").length;
let nr_items = Math.min(nr_items_lg, nr_items_md, nr_items_xs);
let active_item = Math.trunc(nr_items * Math.random());
let active_slide_lg = Math.trunc(active_item / 3);
let active_slide_md = Math.trunc(active_item / 2);
let active_slide_xs = Math.trunc(active_item / 1);
$("#myCarousel div.item").removeClass("active");
$("#myCarouselMedium div.item").removeClass("active");
$("#myCarouselSmall div.item").removeClass("active");
$("#myCarousel div.item").eq(active_slide_lg).addClass("active");
$("#myCarouselMedium div.item").eq(active_slide_md).addClass("active");
$("#myCarouselSmall div.item").eq(active_slide_xs).addClass("active");
});
/* Advance carousel by swiping. */
$(document).ready(function() {
$('.carousel').bcSwipe({ threshold: 50 });
});
/* Defer loading Youtube iframe until the user clicks on the video. */
$(document).ready(function() {
/* For the video preview, we use this for devices without hover events. */
if ("ontouchstart" in document.documentElement) {
$("body").addClass("touch");
}
/* Click handler for all videos. */
$(".camp-video").one("click", function() {
let yt_id = $(this).data("embed");
$(this).html('');
});
});
/* Fill donation amounts w/ javascript if possible. */
$(document).ready(function() {
let vals = ["500", "200", "100", "50", "20", "10", "5"];
for (let value of vals) {
- $(".amount-btn-" + value.toString()).attr("href","#");
- $(".amount-btn-" + value.toString()).one("click",function() {
- $("#amountother").attr("value",value.toString());
+ $(".amount-btn-" + value.toString()).attr("href", "#");
+ $(".amount-btn-" + value.toString()).one("click", function() {
+ $("#amountother").attr("value", value.toString());
+ $("#currency option").attr("selected", false);
+ $("#currency option[value='EUR']").attr("selected", true);
+ $("#recur option").attr("selected", false);
+ $("#recur option[value='12']").attr("selected", true);
});
}
});