This file contains hidden or 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
JSONP is really a simple trick to overcome the XMLHttpRequest same domain policy. (As you know one cannot send AJAX (XMLHttpRequest) request to a different domain.) | |
So - instead of using XMLHttpRequest we have to use script HTML tags, the ones you usually use to load js files, in order for js to get data from another domain. Sounds weird? | |
Thing is - turns out script tags can be used in a fashion similar to XMLHttpRequest! Check this out: | |
script = document.createElement('script'); | |
script.type = 'text/javascript'; | |
script.src = 'http://www.someWebApiServer.com/some-data'; | |
You will end up with a script segment that looks like this after it loads the data: |
This file contains hidden or 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
javascript:[...document.querySelectorAll('img,video,source')].map(e=>e.src&&(e.tagName!='IMG'||e.srcset.includes('1080w'))&&this.open(e.src,'')) |
This file contains hidden or 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
/*! | |
* Font Awesome Pro 5.3.1 by @fontawesome - https://fontawesome.com*/ | |
.fa,.fab,.fal,.far,.fas{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;display:inline-block;font-style:normal;font-variant:normal;text-rendering:auto;line-height:1}.fa-lg{font-size:1.33333em;line-height:.75em;vertical-align:-.0667em}.fa-xs{font-size:.75em}.fa-sm{font-size:.875em}.fa-1x{font-size:1em}.fa-2x{font-size:2em}.fa-3x{font-size:3em}.fa-4x{font-size:4em}.fa-5x{font-size:5em}.fa-6x{font-size:6em}.fa-7x{font-size:7em}.fa-8x{font-size:8em}.fa-9x{font-size:9em}.fa-10x{font-size:10em}.fa-fw{text-align:center;width:1.25em}.fa-ul{list-style-type:none;margin-left:2.5em;padding-left:0}.fa-ul>li{position:relative}.fa-li{left:-2em;position:absolute;text-align:center;width:2em;line-height:inherit}.fa-border{border:.08em solid #eee;border-radius:.1em;padding:.2em .25em .15em}.fa-pull-left{float:left}.fa-pull-right{float:right}.fa.fa-pull-left,.fab.fa-pull-left,.fal.fa-pull-left,.far.fa-pull-left,.fas.fa-pull-left{margi |
This file contains hidden or 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
//document.querySelectorAll('*').forEach(e => e.contentEditable = 'true'); | |
document.designMode = 'on' |
This file contains hidden or 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
// Paste this below code into the console on the youtube: | |
javascript:(function(){var goaway=".ytp-chrome-top,.ytp-chrome-bottom{display:none;}";if("\v"=="v"){document.createStyleSheet().cssText=goaway}else{var tag=document.createElement("style");tag.type="text/css";document.getElementsByTagName("head")[0].appendChild(tag);tag[(typeof document.body.style.WebkitAppearance=="string")?"innerText":"innerHTML"]=goaway}})(); | |
//then you can take a full screen screenshot ;) |
This file contains hidden or 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
var alphabet = "abcdefghijklmnopqrstuvwxyz"; | |
console.log(alphabet[Math.floor(Math.random() * alphabet.length)]); | |
// Priting random 6 letters word | |
var alphabet = "abcdefghijklmnopqrstuvwxyz"; | |
var random = ""; | |
for (i = 0;i < 6 ; i ++) { | |
random = random + alphabet[Math.floor(Math.random() * alphabet.length)]; |
This file contains hidden or 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
You may use this regex with multiple lookahead assertions (conditions): | |
^(?=.*?[A-Z])(?=.*?[a-z])(?=.*?[0-9])(?=.*?[#?!@$%^&*-]).{8,}$ | |
This regex will enforce these rules: | |
At least one upper case English letter, (?=.*?[A-Z]) | |
At least one lower case English letter, (?=.*?[a-z]) | |
At least one digit, (?=.*?[0-9]) | |
At least one special character, (?=.*?[#?!@$%^&*-]) | |
Minimum eight in length .{8,} (with the anchors) |
This file contains hidden or 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
<html><head></head><body><table class="sc-jAaTju fNCBho" cellpadding="0" cellspacing="0" style="vertical-align: -webkit-baseline-middle; font-size: medium; font-family: 'Trebuchet MS';"> | |
<tbody> | |
<tr> | |
<td> | |
<table class="sc-jAaTju fNCBho" cellpadding="0" cellspacing="0" style="vertical-align: -webkit-baseline-middle; font-size: medium; font-family: 'Trebuchet MS'; width: 100%;"> | |
<tbody> | |
<tr> | |
<td height="30"></td> | |
</tr> | |