3 function update_methods() {
4 $("#payment-form .payment-method").addClass("disabled");
5 $("#payment-form .payment-method input").prop("disabled", true);
6 var plan = $("#payment-form .plan:checked");
9 $("#payment-form .plan:checked").attr('data-methods').trim().split(" "),
11 $("#payment-method-" + slug).removeClass("disabled");
12 $("#payment-method-" + slug + " input").prop("disabled", false);
18 $("#payment-form .plan").change(update_methods);
22 key = key.replace(/[*+?^$.\[\]{}()|\\\/]/g, "\\$&"); // escape RegEx meta chars
23 var match = location.search.match(new RegExp("[?&]"+key+"=([^&]+)(&|$)"));
24 return match && decodeURIComponent(match[1].replace(/\+/g, " "));
27 $("#payment-form").submit(function() {
28 let camp = qs('pk_campaign');
29 if (!camp && window.location.pathname !== "/pomagam/") {
30 camp = window.location.pathname;
32 let dims = camp ? {dimension1: camp} : {};
33 _paq.push(['trackGoal', 12, parseFloat($("#id_amount").val()), dims]);