Template:2012FR/Form-section/Processing/Default: Difference between revisions

Content deleted Content added
changes Matt suggested
No edit summary
Line 7:
</style>
<script>
donationForm = {};
 
function redirectPayment (legacyPaymentMethod) {
// wrapper for new function
Line 14 ⟶ 16:
switch (legacyPaymentMethod) {
case 'cc':
mw.donationForm.redirectPaymentWithSubMethod('cc');
break;
 
Line 23 ⟶ 25:
case 'ew-pp-usd':
case 'ew-pp-eur':
mw.donationForm.redirectPaymentWithSubMethod('paypal');
break;
 
case 'dd':
mw.donationForm.redirectPaymentWithSubMethod('dd');
break;
 
case 'rtbt-id':
mw.donationForm.redirectPaymentWithSubMethod('rtbt', 'rtbt_ideal');
break;
 
case 'ew-yd':
mw.donationForm.redirectPaymentWithSubMethod('ew', 'ew_yandex');
break;
 
case 'rtbt-sf':
mw.donationForm.redirectPaymentWithSubMethod('rtbt', 'rtbt_sofortuberweisung');
break;
 
case 'ew-amazon':
mw.donationForm.redirectPaymentWithSubMethod('amazon');
break;
 
case 'obt-bp':
mw.donationForm.redirectPaymentWithSubMethod('obt', 'bpay');
break;
 
case 'ew-wm':
mw.donationForm.redirectPaymentWithSubMethod('ew', 'ew_webmoney');
break;
 
case 'cash-bl':
mw.donationForm.redirectPaymentWithSubMethod('cash', 'boleto');
break;
 
case 'rtbt-en':
mw.donationForm.redirectPaymentWithSubMethod('rtbt', 'rtbt_enets');
break;
}
Line 65 ⟶ 67:
}
 
mw.donationForm.redirectPaymentWithSubMethod = function(paymentMethod, paymentSubMethod) {
 
// set up inputs
Line 111 ⟶ 113:
}
 
mw.donationForm.addAnalytics();
if (validateForm(form)) {
Line 119 ⟶ 121:
}
 
mw.donationForm.addAnalytics = function() {
// stuffs parameters into utm_source to make them available for analytics