MediaWiki:Centralnotice-template-B14 1119 frFR dsk ful blk txt aid
<style> /* Clearfix */
- frbanner .cf:before,
- frbanner .cf:after {
content: ""; display: table;
}
- frbanner .cf:after { clear: both; }
.ie7 #frbanner .cf { zoom: 1; }
/* Border-Box */
- frbanner *,
- frbanner *:before,
- frbanner *:after {
-moz-box-sizing: border-box; -webkit-box-sizing: border-box; box-sizing: border-box;
}
/* Transitions */
- frbanner * {
-webkit-transition: all .3s ease-in-out; -moz-transition: all .3s ease-in-out; -o-transition: all .3s ease-in-out; -ms-transition: all .3s ease-in-out; transition: all .3s ease-in-out;
}
- frbanner {
top: 0 !important; width: 100%;
position: absolute !important; }
/* Window Styles
*/
- frbanner-window {
margin: 0 auto; background: #000; width: 90%; max-width: 1400px; top: 30px; position: relative; -moz-box-shadow: 0 0 10px rgba(90,97,98,.25); -webkit-box-shadow: 0 0 10px rgba(90,97,98,.25); box-shadow: 0 0 10px rgba(90,97,98,.25); font: 1em/1.2em "Helvetica Neue","Helvetica","Nimbus Sans L","Arial","Liberation Sans",sans-serif; color: #3c3c3c;
}
- frbanner-window .frbanner-footer {
background: #1f1f1f; font-size: .7em; line-height: 1; color: #8d8d8d; padding: 1em 4em; text-align: center;
}
- frbanner-window .frbanner-footer a {
color: #d0d0d0; text-decoration: none;
}
- frbanner-window .frbanner-footer a:hover { color: #fff; }
- frbanner-close {
background: url('//upload.wikimedia.org/wikipedia/donate/c/cf/Close-trilogy.png') no-repeat center center; width: 20px; height: 21px; display: block; cursor: pointer; position: absolute; right: 10px; top: 10px; opacity: .5; text-indent: -99999px; z-index: 999;
}
- frbanner-close:hover {
opacity: 1;
}
- modal-signup { display: table; }
/* --- Branding --- */
.frbanner-logo {
margin: .5em 0 1.5em; text-align: center;
}
.frbanner-logo img {
width: 210px; opacity: .6; cursor: pointer;
} .frbanner-logo:hover img { opacity: 1; }
/* --- Message --- */
.frbanner-message {
width: 65%; display: table-cell; vertical-align: top; font-size: 1em; line-height: 1.5; text-align: left; padding: 2em; font-family: "Helvetica Neue Light",Arial, Helvetica, sans-serif; font-weight: bold; color: #fff;
} @media (min-width : 800px) { .frbanner-message { font-size: 1.1em; line-height: 1.5; } } @media (min-width : 900px) { .frbanner-message { font-size: 1.15em; line-height: 1.6; } } @media (min-width : 1000px) { .frbanner-message { font-size: 1.25em; line-height: 1.4; } } @media (min-width : 1100px) { .frbanner-message { font-size: 1.3em; line-height: 1.6; } }
.frbanner-message p {
margin-bottom: .5em; line-height: 1.4;
}
.frbanner-message p:last-child { margin-bottom: 0; }
.frbanner-message strong {
font-family: "Helvetica Neue Bold",Arial, Helvetica, sans-serif; font-style: normal; font-weight: bold; }
.frbanner-message .highlight { background: #fff000; font-weight: bold; color: #000; } .frbanner-message .highlight span { position: relative; } /* prevent background from overlapping text */
/* --- Form --- */
- {{{banner}}}-form {
background: #e2e2e2; width: 40%; display: table-cell; vertical-align: top; height: 100%; padding: 2em 1.8em 2em; position: relative;
} @media (min-width : 960px) { .frbanner-message { width: 75%; }
- {{{banner}}}-form { width: 25%; }
}
- {{{banner}}}-form:before {
position: absolute; left: 0; top: 50%; content: " "; margin: 0; border-color: rgba(255, 255, 255, 0); border: solid transparent; pointer-events: none; border-left-color: #000; border-width: 10px;
}
.frbanner-frequency,
.frbanner-amounts,
.frbanner-submit {
width: 100%; overflow: auto; zoom: 1; margin: 0 auto 0; padding: 0 0 17px; border-bottom: 1px solid #d1d1d1;
}
.frbanner-frequency {
list-style: none;
}
.frbanner-frequency label {
background-color: #e7e7e7; -moz-box-shadow: 0 0 2px rgba(0,0,0,.2), inset 0 14px 16px rgba(255,255,255,.75), inset 0 0 7px #fff; -webkit-box-shadow: 0 0 2px rgba(0,0,0,.2), inset 0 14px 16px rgba(255,255,255,.75), inset 0 0 7px #fff; box-shadow: 0 0 2px rgba(0,0,0,.2), inset 0 14px 16px rgba(255,255,255,.75), inset 0 0 7px #fff; width: 49%; padding: .5em 0; float: left; margin-right: 2%; -moz-border-radius: 4px; -webkit-border-radius: 4px; border-radius: 4px; text-transform: uppercase;
text-align: center;
font-size: .7em; color: #646464; cursor: pointer;
}
.frbanner-frequency .checked {
background: #9f9f9f !important; color: #fff; -moz-box-shadow: inset 0 1px 3px rgba(0,0,0,.5); -webkit-box-shadow: inset 0 1px 3px rgba(0,0,0,.5); box-shadow: inset 0 1px 3px rgba(0,0,0,.5);
}
.frbanner-frequency label.frequency_monthly { margin-right: 0; }
.frbanner-frequency input {
position: relative; top: -3px; vertical-align: middle;
}
@media (min-width : 800px) { .frbanner-frequency label { font-size: .75em; } }
@media (min-width : 900px) { .frbanner-frequency label { font-size: .8em; } }
@media (min-width : 960px) { .frbanner-frequency label { font-size: .9em; } }
@media (min-width : 1160px) { .frbanner-frequency label { font-size: 1em; } }
.frbanner-frequency label:hover {
background-color: #fff; -moz-box-shadow: 0 0 2px rgba(0,0,0,.5), inset 0 14px 16px rgba(255,255,255,.75), inset 0 0 7px #fff; -webkit-box-shadow: 0 0 2px rgba(0,0,0,.5), inset 0 14px 16px rgba(255,255,255,.75), inset 0 0 7px #fff; box-shadow: 0 0 2px rgba(0,0,0,.5), inset 0 14px 16px rgba(255,255,255,.75), inset 0 0 7px #fff; color: #367fb4; }
.frbanner-frequency label:active {
-moz-box-shadow: inset 0 1px 3px rgba(0,0,0,.5); -webkit-box-shadow: inset 0 1px 3px rgba(0,0,0,.5); box-shadow: inset 0 1px 3px rgba(0,0,0,.5); }
.frbanner-amounts li {
display: block; width: 23.5%; float: left; clear: none; margin: 0 2% 6px 0; }
li#amount_total_4, li#amount_other { margin-right: 0; }
.frbanner-amounts li input[type="radio"] {
border: 0; clip: rect(0 0 0 0); height: 1px; margin: -1px; overflow: hidden; padding: 0; position: absolute; width: 1px;
}
.predefined_amount,
- amount_other {
background-color: #e7e7e7; -moz-box-shadow: 0 0 2px rgba(0,0,0,.2), inset 0 14px 16px rgba(255,255,255,.75), inset 0 0 7px #fff; -webkit-box-shadow: 0 0 2px rgba(0,0,0,.2), inset 0 14px 16px rgba(255,255,255,.75), inset 0 0 7px #fff; box-shadow: 0 0 2px rgba(0,0,0,.2), inset 0 14px 16px rgba(255,255,255,.75), inset 0 0 7px #fff; display: block; height: AUTO; padding: .9em 0; font: .8em/22px "Helvetica Neue Roman",Arial, Helvetica, sans-serif; font-style: normal; font-weight: 300; text-align: center; border:none; -moz-border-radius: 4px; -webkit-border-radius: 4px; border-radius: 4px; color: #646464; cursor: pointer; outline: 0; backface-visibility: hidden;
}
.frbanner-amounts li label { width: 100%; }
@media (min-width : 800px) { .predefined_amount, #amount_other { font-size: 1em; height: 60px; } } @media (min-width : 960px) { .predefined_amount, #amount_other { font-size: 1.1em; height: 60px; } } @media (min-width : 1060px) { .predefined_amount, #amount_other { font-size: 1.2em; height: 60px; } }
.frbanner-amounts li label:hover,
- amount_other:hover {
background-color: #fff; -moz-box-shadow: 0 0 2px rgba(0,0,0,.5), inset 0 14px 16px rgba(255,255,255,.75), inset 0 0 7px #fff; -webkit-box-shadow: 0 0 2px rgba(0,0,0,.5), inset 0 14px 16px rgba(255,255,255,.75), inset 0 0 7px #fff; box-shadow: 0 0 2px rgba(0,0,0,.5), inset 0 14px 16px rgba(255,255,255,.75), inset 0 0 7px #fff; color: #367fb4; }
.frbanner-amounts li input[type="radio"]:checked + label,
- amount_other.checked {
background: #9f9f9f !important; color: #fff; -moz-box-shadow: inset 0 1px 3px rgba(0,0,0,.5); -webkit-box-shadow: inset 0 1px 3px rgba(0,0,0,.5); box-shadow: inset 0 1px 3px rgba(0,0,0,.5);
}
/* Fallback for IE8 and below */ /*.frbanner-amounts li label.checked, .checked#amount_other {
background: transparent !important;
}*/
- amount_other { padding: 3px 0 0 0; }
- amount_other label,
- amount_other.checked label { background: transparent !important; }
- amount_other fieldset {
width: 100%; margin: 0; border: none; position: relative; padding: 0 7px; line-height: 1em;
}
- amount_other fieldset label {
position: absolute; left: 10px; top: 3px; color: #fff;
}
- amount_other.checked fieldset label {
color: #0f4b76;
}
- amount_other label {
width: auto !important; padding: 0 !important; font-size: .8em; background: transparent; -moz-box-shadow: none; -webkit-box-shadow: none; box-shadow: none;
}
- amount_other fieldset label {
color: #fff; }
- amount_other .other {
text-transform: uppercase; font-size: 9px; line-height: 1; }
@media (min-width : 1160px) { #amount_other .other { font-size: 11px; } }
- amount_other input {
width: 100%; background: #a4a4a4; border: 0; color: #fff; font-family: "Helvetica Neue Roman",Arial, Helvetica, sans-serif; font-size: 13px; padding: 4px 5px 4px 16px; -moz-border-radius: 4px; -webkit-border-radius: 4px; border-radius: 4px;
}
- amount_other.checked input {
background: #fff; color: #163348;
}
.frbanner-submit li {
width: 100%; float: none; display: block; margin: 0 0 4px;
}
@media (min-width : 1100px) {
.frbanner-submit li {
width: 48%; float: left; display: block; margin: 0 2% 0 0;}
}
.frbanner-submit .paymentmethod-amazon { margin-right: 0; }
- frbanner-window button {
background-color: #e7e7e7; -moz-box-shadow: 0 0 2px rgba(0,0,0,.2), inset 0 14px 16px rgba(255,255,255,.75), inset 0 0 7px #fff; -webkit-box-shadow: 0 0 2px rgba(0,0,0,.2), inset 0 14px 16px rgba(255,255,255,.75), inset 0 0 7px #fff; box-shadow: 0 0 2px rgba(0,0,0,.2), inset 0 14px 16px rgba(255,255,255,.75), inset 0 0 7px #fff; border: none; width: 100%; padding: .4em 0; font-size: .75em; line-height: 1; text-transform: uppercase; color: #646464; cursor: pointer; -moz-border-radius: 4px; -webkit-border-radius: 4px; border-radius: 4px;
} @media (min-width : 980px) {
- frbanner-window button {
font-size: .65em; height: 51px;} }
@media (min-width : 1000px) {
- frbanner-window button {
height: 52px; } }
@media (min-width : 1100px) {
- frbanner-window button {
font-size: .9em; height: 53px; } }
@media (min-width : 1150px) {
- frbanner-window button {
font-size: 1em; height: 54px; } }
- frbanner-window button:hover {
background-color: #fff; -moz-box-shadow: 0 0 2px rgba(0,0,0,.5), inset 0 14px 16px rgba(255,255,255,.75), inset 0 0 7px #fff; -webkit-box-shadow: 0 0 2px rgba(0,0,0,.5), inset 0 14px 16px rgba(255,255,255,.75), inset 0 0 7px #fff; box-shadow: 0 0 2px rgba(0,0,0,.5), inset 0 14px 16px rgba(255,255,255,.75), inset 0 0 7px #fff; color: #367fb4;
}
- frbanner-window button:active {
background-color: #f9f9f9; -moz-box-shadow: 0 0 2px rgba(0,0,0,.2), inset 1px 1px 3px rgba(0,0,0,.3), inset 0 0 7px #fff; -webkit-box-shadow: 0 0 2px rgba(0,0,0,.2), inset 1px 1px 3px rgba(0,0,0,.3), inset 0 0 7px #fff; box-shadow: 0 0 2px rgba(0,0,0,.2), inset 1px 1px 3px rgba(0,0,0,.3), inset 0 0 7px #fff;
}
- frbanner-window strong.error {
background: #e5275d; padding: 3px 5px; display: block; white-space: nowrap; position: absolute; left: 50%; top: 41px; z-index: 9999; font-size: 10px; line-height: 10px; font-weight: 400; color: #fff; text-transform: uppercase;
}
- frbanner-window strong.error:after {
height: 0; width: 0; margin-left: -6px; content: " "; position: absolute; left: 15px; bottom: 100%; border-color: rgba(229, 39, 93, 0); border: solid transparent; pointer-events: none; border-bottom-color: #e5275d; border-width: 6px;
}
- frbanner-window li.subhead {
width: 100% !important; margin: 0; padding: .5em 0; text-align: center; font-size: .75em; text-transform: uppercase; color: #7c7c7c;
}
- frbanner-window .frbanner-explanation {
display: block; text-align: left; font-size: .8em; line-height: 1.2; padding-top: 1.5em; }
- frbanner-window .frbanner-explanation h3 {
font-size: 100%; color: #3c3c3c; }
- frbanner-window .frbanner-explanation h3,
- frbanner-window .frbanner-explanation p { margin-bottom: .8em; line-height:1.2; }
- frbanner-window .frbanner-explanation p:last-child { margin-bottom: 0; }
/* hide methods which aren't monthly capable when monthly option is selected */
.form-monthly .no-monthly {
display: none !important;
} </style>
<script> function clearOther(box) {
document.getElementById("input_amount_other").checked = true; box.value = ""; box.style.color = "#000000";
}
function resetOther(box) {
box.value = "Other";
}
function selectAmount() {
document.getElementById("input_amount_other_box").value = ""; document.getElementsByName("amountGiven")[0].value="";
}
$(document).ready( function () {
$(".frbanner-frequency > label").click(function() { $(".frbanner-frequency > label").removeClass("checked"); $(this).addClass("checked"); });
$(".frbanner-amounts li label, #amount_other").click(function() { $(".frbanner-amounts li label").removeClass("checked"); $("#amount_other").removeClass("checked"); $(this).addClass("checked"); });
$("#amount_other").click(function() { $("input[name='amount']").each(function() { this.checked = false; }); $("#amount_other").addClass("checked"); $("#input_amount_other_box").focus(); });
/* Allow overriding country */ if( mw.util.getParamValue("country") ) { Geo.country = mw.util.getParamValue("country"); }
}); </script>
<script> /**
* NOTE: The following currency mapping is WMF-specific based on payment * provider availability, NOT necessarily the official currency of the country */
function getCurrency() {
switch(Geo.country) { // Big 5 at the top for speed case "US": return "USD"; case "CA": return "CAD"; case "GB": return "GBP"; case "AU": return "AUD"; case "NZ": return "NZD"; // Euro countries case "AD": case "AL": case "AM": case "AT": case "AW": case "AZ": case "BE": case "BY": case "CI": case "CY": case "DE": case "EE": case "ES": case "FI": case "FR": case "GF": case "GR": case "IE": case "IT": case "LT": case "LU": case "LV": case "LY": case "MC": case "ME": case "MG": case "MT": case "NL": case "PT": case "RE": case "RS": case "SI": case "SK": case "SM": case "SR": case "VA": return "EUR"; // The rest case "AE": return "AED"; case "AR": return "ARS"; case "BA": return "BAM"; case "BB": return "BBD"; case "BD": return "BDT"; case "BG": return "BGN"; case "BH": return "BHD"; case "BM": return "BMD"; case "BO": return "BOB"; case "BR": return "BRL"; case "BZ": return "BZD"; case "CH": return "CHF"; case "CK": return "NZD"; case "CL": return "CLP"; case "CN": return "CNY"; case "CO": return "COP"; case "CR": return "CRC"; case "CZ": return "CZK"; case "DK": return "DKK"; case "DO": return "DOP"; case "DZ": return "DZD"; case "EG": return "EGP"; case "FJ": return "FJD"; case "FO": return "DKK"; case "GL": return "DKK"; case "GT": return "GTQ"; case "HK": return "HKD"; case "HN": return "HNL"; case "HR": return "HRK"; case "HU": return "HUF"; case "ID": return "IDR"; case "IL": return "ILS"; case "IN": return "INR"; case "IS": return "ISK"; case "JM": return "JMD"; case "JO": return "JOD"; case "JP": return "JPY"; case "KE": return "KES"; case "KI": return "AUD"; case "KR": return "KRW"; case "KZ": return "KZT"; case "LB": return "LBP"; case "LI": return "CHF"; case "LK": return "LKR"; case "MA": return "MAD"; case "MK": return "MKD"; case "MV": return "MVR"; case "MW": return "GBP"; case "MX": return "MXN"; case "MY": return "MYR"; case "NI": return "NIO"; case "NO": return "NOK"; case "NP": return "INR"; case "NR": return "AUD"; case "OM": return "OMR"; case "PA": return "PAB"; case "PE": return "PEN"; case "PG": return "AUD"; case "PH": return "PHP"; case "PK": return "PKR"; case "PL": return "PLN"; case "PY": return "PYG"; case "QA": return "QAR"; case "RO": return "RON"; case "RU": return "RUB"; case "SA": return "SAR"; case "SD": return "GBP"; case "SE": return "SEK"; case "SG": return "SGD"; case "TH": return "THB"; case "TM": return "RUB"; case "TN": return "TND"; case "TR": return "TRY"; case "TT": return "TTD"; case "TW": return "TWD"; case "UA": return "UAH"; case "UY": return "UYU"; case "UZ": return "RUB"; case "VE": return "VEF"; case "VN": return "VND"; case "VU": return "AUD"; case "ZA": return "ZAR"; // small multi-country currencies case "CW": case "SX": return "ANG"; case "AG": case "DM": case "GD": case "KN": case "LC": return "XCD"; case "BJ": case "BF": case "CI": case "GW": case "ML": case "NE": case "SN": case "TG": return "XOF"; case "PF": case "NC": case "WF": return "XPF"; // fall back to USD default: return "USD"; }
} </script> <script> function currencyLocalize(currency, amount, language){
// Do some basic number formatting - digit separators etc if (window.Intl && typeof window.Intl === "object") { if (Geo.country) { var locale = language + '-' + Geo.country; } else { var locale = language; } var formatter = new Intl.NumberFormat(locale); } else { // boo, bad browser! let's just have a thing that throws it back unformatted for now var formatter = {}; formatter.format = function(number) { return number.toString(); }; } if (isNaN(amount) || amount == "") { // it's probably the "other" string or box var fmAmount = amount; } else { var fmAmount = formatter.format(amount); } // End number formatting
var currencies = { "USD" : "$\t", "EUR" : { "en" : "€\t", "cy" : "€\t", "ga" : "€\t", "mt" : "€\t", "nl" : "€ \t", "lv" : "€ \t", "tr" : "€ \t", "default" : "\t €" }, "AED" : " د.إ \t", "ANG" : "ƒ\t", "ARS" : "$\t", "AUD" : "$\t", "BAM" : "\t KM", "BBD" : "Bcs$\t", "BDT" : "৳\t", "BGN" : "лв\t", "BHD" : "د.ب\t", "BMD" : "BD$\t", "BOB" : "$b\t", "BRL" : "R$\t", "BZD" : "BZ$\t", "CAD" : { "fr" : "$\t", "default" : "$\t" }, "CHF" : "Fr. \t", "CLP" : "$\t", "CNY" : "\t ¥", "COP" : "$\t", "CRC" : "\t ₡", "CZK" : "\t Kč", "DKK" : "\t kr.", "DOP" : "RD$\t", "DZD" : "د.ج\t", "EEK" : "\t kr", "EGP" : { "en" : "E£\t", "default" : "\t جنيه" }, "FJD" : "FJ$\t", "GBP" : "£\t", "GTQ" : "Q\t", "HKD" : "HK$\t", "HNL" : "L\t", "HRK" : "\t kn", "HUF" : "\t Ft", "IDR" : "Rp \t", "ILS" : { "he" : "\t ₪", "yi" : "\t ₪", "ar" : "\t ₪", "default" : "₪ \t" }, "INR" : "₹ \t", "ISK" : "\t kr", "JMD" : "J$ \t", "JOD" : "دينار\t", "JPY" : "¥\t", "KES" : "\t KSh", "KRW" : "₩\t", "KWD" : "د.ك \t", "KZT" : "〒 \t", // TODO: don't use the JP postal code symbol once KZT works in unicode "LBP" : "LBP \t", "LKR" : "\t Rs.", "LTL" : "\t Lt", "LVL" : "\t Ls", "MAD" : "د.م.\t", "MKD" : "\t ден", "MOP" : "MOP$\t", "MUR" : "\t Rs", "MXN" : "$\t", "MVR" : "Rf. \t", "MYR" : "RM\t", "NIO" : "C$\t", "NOK" : "\t kr", "NZD" : "$\t", "OMR" : "ر.ع\t", "PAB" : "\t B/.", "PEN" : "S/. \t", "PHP" : "₱\t", "PKR" : "Rs \t", "PLN" : "\t zł", "PYG" : "\t ₲", "QAR" : "ر.ق\t", "RON" : "\t lei", "RUB" : "\t руб", "SAR" : "﷼\t", "SCR" : "SR \t", "SEK" : "\t kr", "SGD" : "S$ \t", "SVC" : "\t ₡", "THB" : { "th" : "\t บาท", "default" : "\t ฿" }, "TND" : "\t د.ت", "TRY" : "₺\t", "TTD" : "TT$\t", "TWD" : "NT$\t", "TZS" : "\t/=", "UAH" : "₴\t", "UYU" : "$U \t", "UZS" : "\t сўм", "VEF" : "Bs.F. \t", "VND" : "\t₫", "VUV" : "VT\t", "XAF" : "FCFA\t", "XCD" : "EC$\t", "XOF" : "CFA \t", "XPF" : "\t F", "ZAR" : "R \t" }; if(currencies[currency] == null){ return currency + " " + fmAmount; } if( currencies[currency] instanceof Object ){ // not a string if(currencies[currency][language] != null){ return currencies[currency][language].replace("\t", fmAmount); } return currencies[currency]["default"].replace("\t", fmAmount); } return currencies[currency].replace("\t", fmAmount);
} </script> <script> function getMinimum(currency){
var minimums = { 'ADF' : 5.95, 'ADP' : 150.87, 'AED' : 3.67, 'AFA' : 60.47, 'AFN' : 60.47, 'ALL' : 124.74, 'AMD' : 473.47, 'ANG' : 1.82, 'AOA' : 122.35, 'AON' : 122.35, 'ARS' : 14, // Astropay 'ATS' : 12.48, 'AUD' : 1.35, 'AWG' : 1.79, 'AZM' : 3926.19, 'AZN' : 1.05, 'BAM' : 1.77, 'BBD' : 2, 'BDT' : 76.04, 'BEF' : 36.58, 'BGL' : 1.77, 'BGN' : 1.77, 'BHD' : 0.37, 'BIF' : 1599.65, 'BMD' : 1, 'BND' : 1.33, 'BOB' : 6.71, 'BRL' : 3.2, 'BSD' : 0.99, 'BTN' : 63.52, 'BWP' : 9.89, 'BYR' : 15378.7, 'BZD' : 1.96, 'CAD' : 1.27, 'CDF' : 912.52, 'CHF' : 0.95, 'CLP' : 980, // Astropay 'CNY' : 6.09, 'COP' : 4000, // Astropay 'CRC' : 523.08, 'CUC' : 1, 'CUP' : 23.15, 'CVE' : 99.81, 'CYP' : 0.53, 'CZK' : 24.59, 'DEM' : 1.77, 'DJF' : 177.72, 'DKK' : 6.77, 'DOP' : 44.46, 'DZD' : 99.04, 'ECS' : 25588.54, 'EEK' : 14.19, 'EGP' : 7.81, 'ESP' : 150.87, 'ETB' : 20.5, 'EUR' : 0.91, 'FIM' : 5.39, 'FJD' : 2.11, 'FKP' : 0.65, 'FRF' : 5.95, 'GBP' : 0.65, 'GEL' : 2.25, 'GHC' : 37964.2, 'GHS' : 3.8, 'GIP' : 0.65, 'GMD' : 38.45, 'GNF' : 7251.79, 'GRD' : 308.97, 'GTQ' : 7.43, 'GYD' : 197.27, 'HKD' : 7.75, 'HNL' : 21.27, 'HRK' : 6.87, 'HTG' : 52.41, 'HUF' : 287.8, 'IDR' : 13333.3, 'IEP' : 0.71, 'ILS' : 3.79, 'INR' : 63.39, 'IQD' : 1141.95, 'IRR' : 29360, 'ISK' : 133.46, 'ITL' : 1755.66, 'JMD' : 113.71, 'JOD' : 0.71, 'JPY' : 121.58, 'KES' : 98.48, 'KGS' : 62.13, 'KHR' : 3995.54, 'KMF' : 445, 'KPW' : 135.01, 'KRW' : 1134.04, 'KWD' : 0.3, 'KYD' : 0.82, 'KZT' : 183.31, 'LAK' : 7923.05, 'LBP' : 1480.9, 'LKR' : 130.3, 'LRD' : 85, 'LSL' : 12.5, 'LTL' : 3.13, 'LUF' : 36.58, 'LVL' : 0.64, 'LYD' : 1.34, 'MAD' : 9.77, 'MDL' : 18.71, 'MGA' : 3252.88, 'MGF' : 9149.13, 'MKD' : 55.45, 'MMK' : 1111.03, 'MNT' : 1958, 'MOP' : 7.79, 'MRO' : 320.47, 'MTL' : 0.39, 'MUR' : 34.3, 'MVR' : 14.97, 'MWK' : 441.83, 'MXN' : 24, // Astropay 'MYR' : 3.8, 'MZM' : 38000, 'MZN' : 38, 'NAD' : 12.5, 'NGN' : 196.44, 'NIO' : 26.24, 'NLG' : 2, 'NOK' : 8.2, 'NPR' : 99.74, 'NZD' : 1.5, 'OMR' : 0.38, 'PAB' : 1, 'PEN' : 3.12, 'PGK' : 2.68, 'PHP' : 45.15, 'PKR' : 100.4, 'PLN' : 3.83, 'PTE' : 181.78, 'PYG' : 5065.03, 'QAR' : 3.64, 'ROL' : 40637.3, 'RON' : 4.06, 'RSD' : 108.68, 'RUB' : 57.16, 'RWF' : 721.7, 'SAR' : 3.75, 'SBD' : 7.83, 'SCR' : 12.33, 'SDD' : 592.4, 'SDG' : 5.92, 'SDP' : 2272.21, 'SEK' : 8.5, 'SGD' : 1.35, 'SHP' : 0.62, 'SIT' : 217.29, 'SKK' : 27.32, 'SLL' : 4158, 'SOS' : 673, 'SRD' : 3.24, 'SRG' : 3240, 'STD' : 22115.7, 'SVC' : 8.54, 'SYP' : 217.65, 'SZL' : 12.5, 'THB' : 33.94, 'TJS' : 6.26, 'TMM' : 14285.71, 'TMT' : 2.85, 'TND' : 1.97, 'TOP' : 2.16, 'TRL' : 2687990, 'TRY' : 2.69, 'TTD' : 6.25, 'TWD' : 31.04, 'TZS' : 2185.91, 'UAH' : 21.25, 'UGX' : 3454.24, 'USD' : 1, 'UYU' : 40, // Astropay 'UZS' : 2541, 'VEB' : 6290.36, 'VEF' : 6.29, 'VND' : 21482.8, 'VUV' : 104.5, 'WST' : 2.36, 'XAF' : 595.84, 'XAG' : 0.07, 'XAU' : 0, 'XCD' : 2.69, 'XEU' : 0.91, 'XOF' : 595.83, 'XPD' : 0, 'XPF' : 108.27, 'XPT' : 0, 'YER' : 214.8, 'YUN' : 108.68, 'ZAR' : 12.5, 'ZMK' : 5327.65, 'ZWD' : 376.36 };
if($.inArray(currency, minimums)){ return minimums[currency]; }
return 1;
} </script>
<style> /* No monthly for Worldpay */ .frequency-options input, .frequency-options label, .frbanner-frequency, .recurring-details {
display: none;
} </style> <script> /**
* Core code for forms in banners. * Handles showing the correct payment methods, validating input, and sending on to payments wiki. * (Note that localizing amount options is done elsewhere, in BannerFormAmountOptions.js) * * Dependencies: FR2013/Resources/CurrencyMinimums.js * FR2013/Resources/Country2Currency.js */
function checkPaymentOutages() {
/* Check against the scheduled payment method outages below * and hide the relevant button for any which are ongoing. */ /* This file can be used to schedule hiding of individual payment methods from banners * e.g. if they have scheduled downtime. * * Valid methods are: * ideal, cc, pp, amazon, bpay, webmoney, cash, pp-usd * (most of the time it's 'ideal'...) * Can also limit outage to a specific country with country: "XX" (where XX is an ISO code) * * Note that in JavaScript dates the months (and only the months) start at 0. * Jan=0, Feb=1, Mar=2, Apr=3 etc. How hateful. * * Be sure to also update donatewiki if needed e.g. by commenting the method templates * found at https://donate.wikimedia.org/wiki/Template:2012FR/Form-section/Paymentmethods * */
var outages = [
{ start: new Date(Date.UTC(2016, 8, 18, 1)), end: new Date(Date.UTC(2016, 8, 18, 7)), method: "ideal" }
];
var now = new Date();
for (var i = outages.length - 1; i >= 0; i--) { if ( now > outages[i]['start'] && now < outages[i]['end'] ) { if (outages[i]['country'] === undefined || outages[i]['country'] == Geo.country) { $('.paymentmethod-' + outages[i]['method']).hide(); } } };
}
function validateForm(form) {
var error = true; // Get amount selection var amount = null; for (var i = 0; i < form.amount.length; i++) { if (form.amount[i].checked) { amount = form.amount[i].value; } } if (form.amountGiven.value != ) { var otherAmount = form.amountGiven.value; otherAmount = otherAmount.replace(/[,.](\d)$/, '\:$10'); otherAmount = otherAmount.replace(/[,.](\d)(\d)$/, '\:$1$2'); otherAmount = otherAmount.replace(/[\$,.]/g, ); otherAmount = otherAmount.replace(/:/, '.'); form.amountGiven.value = otherAmount; amount = otherAmount; } // Check amount is a real number error = ( amount == null || isNaN(amount) || amount.value <= 0 ); // Check amount is at least the minimum var currency = form.currency_code.value; if (amount < getMinimum(currency) || error) { alert('You must contribute at least $1'.replace('$1', getMinimum(currency) + ' ' + currency)); error = true; } return !error;
}
function redirectPayment(paymentMethod, paymentSubMethod, skipValidation) {
if (typeof paymentSubMethod == 'undefined'){ paymentSubMethod = ; } var form = document.paypalcontribution; // we should really change this some day var language = $("input[name='language']").val(); var paymentsURL = 'https://payments.wikimedia.org/index.php/Special:GatewayFormChooser'; var params = { 'uselang' : language, 'language' : language, 'currency_code' : $("input[name='currency_code']").val(), 'country' : $("input[name='country']").val(), 'paymentmethod' : paymentMethod }; if( paymentSubMethod != ){ params['submethod'] = paymentSubMethod; } // WorldPay override for cc if( paymentMethod === 'cc' ) { params.gateway = 'worldpay'; params.ffname = 'worldpay'; }
var frequency = $("input[name='frequency']:checked").val(); if( frequency !== 'monthly' ){ frequency = 'onetime'; } else { params['recurring'] = 'true'; // the following line is both obsolete, and is causing errors. // paymentMethod = 'r' + paymentMethod; } form.action = paymentsURL + '?' + $.param(params); form.payment_method.value = paymentMethod; if( paymentSubMethod != ) { form.payment_method.value = form.payment_method.value + '.' + paymentSubMethod; } form.utm_source.value = '{{{banner}}}.no-LP' + '.' + form.payment_method.value; if (skipValidation || validateForm(document.paypalcontribution)) { form.submit(); }
}
function toggleMonthly( monthly ){
if( monthly.type === 'checkbox' ){ monthly = monthly.checked; } if (monthly) { $('#{{{banner}}}-form').addClass('form-monthly'); } else { $('#{{{banner}}}-form').removeClass('form-monthly'); }
}
$(document).ready( function () {
if ( wgCanonicalSpecialPageName != "CentralNotice" && wgCanonicalSpecialPageName != "NoticeTemplate" ) { mw.centralNotice.events.bannerLoaded.done(function(e){ $('[name="paypalcontribution"]').append($('<input>', { 'type': 'hidden', 'name': 'utm_key', 'value': (mw.centralNotice.bannerData.cookieCount || 0) })); }); var currency = getCurrency(Geo.country); var language = mw.config.get('wgUserLanguage'); // hide CC or PP buttons anywhere we need to var noCC = []; if ($.inArray(Geo.country, noCC) != -1) { $(".paymentmethod-cc").remove(); } var noPP = ['IN', 'RU', 'SG', 'AE', 'QA', 'JP', 'OM', 'BD', 'BO', 'PA', 'PE', 'PY', 'GT', 'JM', 'TT', 'DZ']; if ($.inArray(Geo.country, noPP) != -1){ $(".paymentmethod-pp").remove(); }
// countries where PP must be in USD var ppUSD = ['BG', 'HR', 'LT', 'MK', 'RO', 'UA', 'SA', 'CN', 'ID', 'KR', 'KZ', 'MY', 'VN', 'AR', 'CL', 'DO', 'CO', 'NI', 'UY', 'ZA', 'BH', 'LB', 'VE', 'TR', 'IS', 'BA', 'MV', 'BB', 'BM', 'BZ', 'CR', 'CW', 'SX', 'HN', 'KN', 'DM', 'AG', 'LC', 'GD', 'FJ', 'TN', 'BJ', 'BF', 'CI', 'GW', 'ML', 'NE', 'SN', 'TG']; if ($.inArray(Geo.country, ppUSD) != -1){ $(".paymentmethod-pp").remove(); $(".paymentmethod-pp-usd").show(); } // can't do monthly credit card in India if (Geo.country === 'IN') { $(".paymentmethod-cc").addClass("no-monthly"); } // show any extra local payment methods, or remove them if not needed var extrapaymentmethods = { 'amazon' : ['US'], 'bpay' : ['AU'], 'ideal' : ['NL'], 'yandex' : ['RU'], 'webmoney' : ['RU'], 'dd' : ['AT', 'DE', 'ES', 'NL'], // 'boletos' : ['BR'], 'enets' : ['SG'], 'sofort' : [] }; for (var method in extrapaymentmethods) { var $methodbutton = $('.paymentmethod-' + method); if ($.inArray(Geo.country, extrapaymentmethods[method]) != -1) { // country is in the list $methodbutton.show(); } else { $methodbutton.remove(); } } checkPaymentOutages(); // set the form fields $("input[name='country']").val(Geo.country); $("input[name='currency_code']").val(currency); $("input[name='language']").val(mw.config.get('wgUserLanguage')); $("input[name='return_to']").val("Thank_You/" + mw.config.get('wgUserLanguage')); // handle pressing Enter on "Other" field $('input[name="amountGiven"]').keydown(function(e){ if (e.keyCode == 13) { e.preventDefault(); redirectPayment('cc'); // use credit card by default. Might be nice to have different defaults for some countries, but this will do for now. return false; } }); // if there are no recurring payment methods available, disable the "monthly" radio button. if ( !$('#{{{banner}}}-form *[class^="paymentmethod-"]:not(.no-monthly)').length ) { $('#frequency_monthly').prop('disabled', 'disabled'); } }
}); </script>
<script> /* Localize links e.g. to "Problems donating"
* by adding language and country parameters */
$(document).ready( function () {
mw.loader.using(['mediawiki.util']).then(function() {
var language = mw.config.get('wgUserLanguage'), country = mw.util.getParamValue('country') || Geo.country;
$('a.localize').each(function() { var url = $(this).attr("href"); if( url.indexOf("?") === -1 ) { url = url + "?"; } else { url = url + "&"; } $(this).attr("href", url + "country=" + country + "&language=" + language + "&uselang=" + language); });
});
}); /* For fullscreen banners which will only be shown once
* After showing them, set a cookie so they don't show up again * and move the user into bucket C/D */
var fundraisingBanner = fundraisingBanner || {};
fundraisingBanner.show = function() {
$('body').prepend($('#centralNotice')); $('#{{{banner}}}').css('display', 'block');
};
fundraisingBanner.hide = function() {
// It's a fullscreen, so they will presumably always hide it $('#{{{banner}}}').hide(); // After it's gone, safe to remove these bindings $(document).off('keyup.bannerHide'); $(document).off('click.bannerHide');
};
fundraisingBanner.changeBucket = function() {
/* Move user to bucket C or D for this campaign Although if it was just a test (no campaign) then don't bother */
if ( !mw.centralNotice.data.getVars.banner ) { var newBucket = Math.floor(Math.random() * 2) + 2; mw.cnBannerControllerLib.bucketsByCampaign['{{{campaign}}}'].val = newBucket; mw.cnBannerControllerLib.storeBuckets(); }
};
(function(mw) {
// See https://stackoverflow.com/questions/6125330/javascript-navigator-cookieenabled-browser-compatibility#15582757 var cookiesEnabled = ('cookie' in document && (document.cookie.length > 0 || (document.cookie = 'test').indexOf.call(document.cookie, 'test') > -1));
var countCookieName = 'centralnotice_bannercount_fr12', cookieCount = parseInt($.cookie(countCookieName), 10) || 0, forced = document.location.search.match(/\bforce=1/);
if ( cookiesEnabled ) {
if ( $.cookie('centralnotice-frbanner-seen-fullscreen') && !forced ) { // Already seen a full-screen banner, so hide this one (unless forced) mw.centralNotice.bannerData.hideResult = true; mw.centralNotice.bannerData.hideReason = 'seen-fullscreen'; } else { mw.centralNotice.bannerData.hideResult = false;
// Increment cookie counter cookieCount += 1; mw.centralNotice.bannerData.cookieCount = cookieCount; $.cookie(countCookieName, cookieCount, { expires: 365 });
// And set a cookie to remember they saw a fullscreen $.cookie('centralnotice-frbanner-seen-fullscreen', Date.now(), {expires: 250}); }
} else { mw.centralNotice.bannerData.hideResult = true; mw.centralNotice.bannerData.hideReason = 'cookies-disabled'; }
// Either way, we should bump them into Bucket C/D now fundraisingBanner.changeBucket();
})(mediaWiki);
/* Close fullscreen banner on pressing ESC */ $(document).on('keyup.bannerHide', function(e) {
if (e.keyCode === 27) { fundraisingBanner.hide(); }
});
/* Close fullscreen banner when clicked outside */ $(document).on('click.bannerHide', function(e) {
if ($(e.target).closest("#frbanner-window").length === 0) { fundraisingBanner.hide(); }
});
$(document).ready(function() {
// Actually show it if needed if (mw.centralNotice.bannerData.hideResult === false) { fundraisingBanner.show(); }
});
mediaWiki.centralNotice.bannerData.alterImpressionData = function( impressionData ) {
// Returning true from this function indicates the banner was shown if (mediaWiki.centralNotice.bannerData.hideReason) { impressionData.reason = mediaWiki.centralNotice.bannerData.hideReason; } if (mediaWiki.centralNotice.bannerData.cookieCount) { impressionData.banner_count = mediaWiki.centralNotice.bannerData.cookieCount; } return !mediaWiki.centralNotice.bannerData.hideResult;
}; </script>