Template:Appeal/FY2324 E3 XH/en: Difference between revisions
Jump to navigation
Jump to search
Content deleted Content added
No edit summary |
Prevent XSS attack using .textContent |
||
(6 intermediate revisions by the same user not shown) | |||
Line 49: | Line 49: | ||
const urlParams = new URLSearchParams(window.location.search); |
const urlParams = new URLSearchParams(window.location.search); |
||
const firstName = urlParams.get("fname"); |
const firstName = urlParams.get("fname"); |
||
if (firstName |
if (firstName){ |
||
const capitalizedName = firstName.charAt(0).toUpperCase() + firstName.slice(1); //Capitalize name |
if(firstName !== 'Wikimedia Supporter'){ |
||
const capitalizedName = firstName.charAt(0).toUpperCase() + firstName.slice(1); //Capitalize name |
|||
document.getElementById('donor-greeting'). |
document.getElementById('donor-greeting').textContent = `${capitalizedName}, s`; |
||
} |
|||
} |
} |
||
</script> |
</script> |
Latest revision as of 00:50, 4 November 2023
Support Wikipedia, your daily source of trusted knowledge.
Your support matters! Sustain this great fountain of knowledge built by people, for people. Keep Wikipedia thriving.