youtube_circumvent_sign_in.user.js - www.codemadness.org - www.codemadness.org saait content files
(HTM) git clone git://git.codemadness.org/www.codemadness.org
(DIR) Log
(DIR) Files
(DIR) Refs
(DIR) README
(DIR) LICENSE
---
youtube_circumvent_sign_in.user.js (820B)
---
1 // ==UserScript==
2 // @name Youtube circumvent verify age
3 // @namespace -
4 // @include http://www.youtube.com/*
5 // @include http://youtube.com/*
6 // @include https://www.youtube.com/*
7 // @include https://youtube.com/*
8 // @version 1
9 // ==/UserScript==
10 //
11 (function() {
12 // Old age verification.
13 var url = location.href;
14 if(url.search(/verify_age/i) != -1) {
15 var matches = location.href.match(/watch%3Fv%3D([^&%]*)/);
16 if(matches.length > 1)
17 location.href = 'http://youtube.com/v/' + matches[1];
18 }
19 // New age verification.
20 if(typeof(document.getElementById('watch7-player-age-gate-content')) != 'undefined') {
21 var matches = location.href.match(/watch\?v=([^&%]*)/);
22 if(matches.length > 1)
23 location.href = 'http://youtube.com/v/' + matches[1];
24 }
25
26 })();