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

From Donate
Jump to navigation Jump to search
Content deleted Content added
No edit summary
strip legacy function, no longer used
Line 4: Line 4:


function redirectPayment (legacyPaymentMethod) {
function redirectPayment (legacyPaymentMethod) {
return undefined;
// wrapper for new function
// using old method parameters
// until buttons can be updated

switch (legacyPaymentMethod) {
case 'cc':
donationForm.redirectPayment('cc');
break;

case 'paypal':
case 'pp':
case 'ew-pp':
case 'ew-rpp':
case 'ew-pp-usd':
case 'ew-pp-eur':
donationForm.redirectPayment('paypal');
break;

case 'dd':
donationForm.redirectPayment('dd');
break;

case 'rtbt-id':
donationForm.redirectPayment('rtbt', 'rtbt_ideal');
break;

case 'ew-yd':
donationForm.redirectPayment('ew', 'ew_yandex');
break;

case 'rtbt-sf':
donationForm.redirectPayment('rtbt', 'rtbt_sofortuberweisung');
break;

case 'ew-amazon':
donationForm.redirectPayment('amazon');
break;

case 'obt-bp':
donationForm.redirectPayment('obt', 'bpay');
break;

case 'ew-wm':
donationForm.redirectPayment('ew', 'ew_webmoney');
break;

case 'cash-bl':
donationForm.redirectPayment('cash', 'boleto');
break;

case 'rtbt-en':
donationForm.redirectPayment('rtbt', 'rtbt_enets');
break;
}

}
}


Line 110: Line 56:
donationForm.addAnalytics();
donationForm.addAnalytics();
if (skipValidation || validateForm(form)) {
if (validateForm(form) || skipValidation) {
form.method = "POST";
form.method = "POST";
form.submit();
form.submit();

Revision as of 14:45, 6 January 2014