This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
whois("example.com").then((response) => console.log(response)); | |
async function fetchEndpoint(extension) { | |
let endpoint; | |
try { | |
let response = await fetch("https://data.iana.org/rdap/dns.json"); | |
let data = await response.json(); | |
let services = data["services"]; | |
let service = services.find((s) => s[0].includes(extension)); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Load Image | |
* @param string $path | |
* @return resource|false | |
*/ | |
function loadImage(string $path) | |
{ | |
return imagecreatefromstring(file_get_contents($path)); |