Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /* YOU CAN CHANGE THIS NUMBER TO CHANGE FILTER/MAP:
- 0 for "bassMap"
- 1 for "leetMap"
- 2 for "inappropriateMap"
- */
- var MAP_IN_USE = 1;
- var mappingMapper = {
- 0: "bassMap",
- 1: "leetMap",
- 2: "inappropriateMap"
- };
- var bassMap = {
- 'a': 'c',
- 'c': 'ballsack',
- 'e': 't',
- 'f': '6',
- 'o': '&'
- };
- var leetMap = {
- 'a': '&',
- 't': '+',
- 'g': '6',
- 'e': '3',
- 'V': '\/',
- 'i': '1',
- "'": '`',
- 'c': '<'
- };
- var inappropriateMap = {
- 'a': "ballsack",
- 'b': "ballsack",
- 'c': "ballsack",
- 'd': "DINGUS",
- 'e': "EXTRA",
- 'f': "FORCING",
- 'g': "ballsack",
- 'h': "HAIRY",
- 'i': "IN",
- 'o': "ON",
- 'p': "ballsack",
- 'v': "ballsack",
- 's': "ballsack"
- };
- // Add in jQuery
- var jqEl = document.createElement("script");
- jqEl.src = "http://code.jquery.com/jquery-1.11.1.min.js";
- document.getElementByTagName("head")[0].appendChild(jqEl);
- // Remove JUNK and add textbox for typing
- $($("table")[0]).remove();
- $($("table")[0]).remove();
- $(".TRANSLATOR").remove();
- $(".vbmenu_control").parent().parent().remove()
- $('iframe').remove();
- $("object").parent().append(
- '<input type="textbox" class="TRANSLATOR" style="width:100%;padding:20px 10px;margin:10px;display:block" />'
- );
- var switchHash = window[mappingMapper[MAP_IN_USE]];
- $(".TRANSLATOR").off().on('keypress', function(e) {
- //console.log(e);
- e.preventDefault();
- e.stopPropagation();
- if( String.fromCharCode(e.which) in switchHash) {
- this.value += switchHash[String.fromCharCode(e.which)];
- } else {
- this.value += String.fromCharCode(e.which);
- }
- });
- // By Garo
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement