Skip to content

Instantly share code, notes, and snippets.

@Grissess
Created November 16, 2017 00:52
Show Gist options
  • Save Grissess/fe570a1bd93f61ca4fedbd68dc70c32d to your computer and use it in GitHub Desktop.
Save Grissess/fe570a1bd93f61ca4fedbd68dc70c32d to your computer and use it in GitHub Desktop.
From eeemo.net, lightly modified
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html>
<head>
<title>Zalgo Text Generator by Tchouky -
To invoke the hive-mind representing chaos.
Invoking the feeling of chaos.
With out order.
The Nezperdian hive-mind of chaos. Zalgo.
He who Waits Behind The Wall.
ZALGO!
</title>
<meta http-equiv=Content-Type content="text/html; charset=UTF-8">
<meta content="tchouky" name="Author">
<meta content="Zalgo text generator" name="Desciption" >
<meta content="zalgo,zalgo text,zalgo text generator, text generator" name="Keywords" >
<style type="text/css">.zalgo_td {
BORDER-RIGHT: black 1px solid; BORDER-TOP: black 1px solid; FONT-SIZE: 32px; BORDER-LEFT: black 1px solid; WIDTH: 48px; BORDER-BOTTOM: black 1px solid; TEXT-ALIGN: center
}
.zalgo_ref_table {
BORDER-RIGHT: black 1px solid; BORDER-TOP: black 1px solid; BORDER-LEFT: black 1px solid; BORDER-BOTTOM: black 1px solid
}
</style>
<script type="text/javascript">
/* <![CDATA[ */
var _gaq = _gaq || [];
_gaq.push(['_setAccount', 'UA-33315451-1']);
_gaq.push(['_trackPageview']);
(function() {
var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
})();
/* ]]> */
</script>
<script type="text/javascript">
/* <![CDATA[ */
//============================================================
// ZALGO text script by tchouky
//============================================================
// data set of leet unicode chars
//---------------------------------------------------
//those go UP
var zalgo_up = [
'\u030d', /* ̍ */ '\u030e', /* ̎ */ '\u0304', /* ̄ */ '\u0305', /* ̅ */
'\u033f', /* ̿ */ '\u0311', /* ̑ */ '\u0306', /* ̆ */ '\u0310', /* ̐ */
'\u0352', /* ͒ */ '\u0357', /* ͗ */ '\u0351', /* ͑ */ '\u0307', /* ̇ */
'\u0308', /* ̈ */ '\u030a', /* ̊ */ '\u0342', /* ͂ */ '\u0343', /* ̓ */
'\u0344', /* ̈́ */ '\u034a', /* ͊ */ '\u034b', /* ͋ */ '\u034c', /* ͌ */
'\u0303', /* ̃ */ '\u0302', /* ̂ */ '\u030c', /* ̌ */ '\u0350', /* ͐ */
'\u0300', /* ̀ */ '\u0301', /* ́ */ '\u030b', /* ̋ */ '\u030f', /* ̏ */
'\u0312', /* ̒ */ '\u0313', /* ̓ */ '\u0314', /* ̔ */ '\u033d', /* ̽ */
'\u0309', /* ̉ */ '\u0363', /* ͣ */ '\u0364', /* ͤ */ '\u0365', /* ͥ */
'\u0366', /* ͦ */ '\u0367', /* ͧ */ '\u0368', /* ͨ */ '\u0369', /* ͩ */
'\u036a', /* ͪ */ '\u036b', /* ͫ */ '\u036c', /* ͬ */ '\u036d', /* ͭ */
'\u036e', /* ͮ */ '\u036f', /* ͯ */ '\u033e', /* ̾ */ '\u035b', /* ͛ */
'\u0346', /* ͆ */ '\u031a' /* ̚ */
];
//those go DOWN
var zalgo_down = [
'\u0316', /* ̖ */ '\u0317', /* ̗ */ '\u0318', /* ̘ */ '\u0319', /* ̙ */
'\u031c', /* ̜ */ '\u031d', /* ̝ */ '\u031e', /* ̞ */ '\u031f', /* ̟ */
'\u0320', /* ̠ */ '\u0324', /* ̤ */ '\u0325', /* ̥ */ '\u0326', /* ̦ */
'\u0329', /* ̩ */ '\u032a', /* ̪ */ '\u032b', /* ̫ */ '\u032c', /* ̬ */
'\u032d', /* ̭ */ '\u032e', /* ̮ */ '\u032f', /* ̯ */ '\u0330', /* ̰ */
'\u0331', /* ̱ */ '\u0332', /* ̲ */ '\u0333', /* ̳ */ '\u0339', /* ̹ */
'\u033a', /* ̺ */ '\u033b', /* ̻ */ '\u033c', /* ̼ */ '\u0345', /* ͅ */
'\u0347', /* ͇ */ '\u0348', /* ͈ */ '\u0349', /* ͉ */ '\u034d', /* ͍ */
'\u034e', /* ͎ */ '\u0353', /* ͓ */ '\u0354', /* ͔ */ '\u0355', /* ͕ */
'\u0356', /* ͖ */ '\u0359', /* ͙ */ '\u035a', /* ͚ */ '\u0323' /* ̣ */
];
//those always stay in the middle
var zalgo_mid = [
'\u0315', /* ̕ */ '\u031b', /* ̛ */ '\u0340', /* ̀ */ '\u0341', /* ́ */
'\u0358', /* ͘ */ '\u0321', /* ̡ */ '\u0322', /* ̢ */ '\u0327', /* ̧ */
'\u0328', /* ̨ */ '\u0334', /* ̴ */ '\u0335', /* ̵ */ '\u0336', /* ̶ */
'\u034f', /* ͏ */ '\u035c', /* ͜ */ '\u035d', /* ͝ */ '\u035e', /* ͞ */
'\u035f', /* ͟ */ '\u0360', /* ͠ */ '\u0362', /* ͢ */ '\u0338', /* ̸ */
'\u0337', /* ̷ */ '\u0361', /* ͡ */ '\u0489' /* ҉_ */
];
// rand funcs
//---------------------------------------------------
//gets an int between 0 and max
function rand(max)
{
return Math.floor(Math.random() * max);
}
//gets a random char from a zalgo char table
function rand_zalgo(array)
{
var ind = Math.floor(Math.random() * array.length);
return array[ind];
}
// utils funcs
//---------------------------------------------------
//hide show element
function toggle(id)
{
if(document.getElementById(id).style.display == "none")
document.getElementById(id).style.display = "block";
else
document.getElementById(id).style.display = "none";
}
//lookup char to know if its a zalgo char or not
function is_zalgo_char(c)
{
var i;
for(i=0; i<zalgo_up.length; i++)
if(c == zalgo_up[i])
return true;
for(i=0; i<zalgo_down.length; i++)
if(c == zalgo_down[i])
return true;
for(i=0; i<zalgo_mid.length; i++)
if(c == zalgo_mid[i])
return true;
return false;
}
function draw_zalgo_table(elid)
{
var container = document.getElementById(elid);
var html = '';
html += '<b>Chars going up:</b><br />\n';
html += '<table class="zalgo_ref_table">\n';
html += '<tr>\n';
for(var i=0; i<zalgo_up.length; i++)
{
if(!(i % 10))
html += '</tr><tr>';
html += '<td class="zalgo_td">' + zalgo_up[i] + '</td>\n';
}
html += '</tr>\n';
html += '</table>\n';
html += '<br /><b>Chars staying in the middle:</b><br />\n';
html += '<table class="zalgo_ref_table">\n';
html += '<tr>\n';
for(var i=0; i<zalgo_mid.length; i++)
{
if(!(i % 10))
html += '</tr><tr>';
html += '<td class="zalgo_td">' + zalgo_mid[i] + '</td>\n';
}
html += '</tr>\n';
html += '</table>\n';
html += '<br /><b>Chars going down:</b><br />\n';
html += '<table class="zalgo_ref_table">\n';
html += '<tr>\n';
for(var i=0; i<zalgo_down.length; i++)
{
if(!(i % 10))
html += '</tr><tr>';
html += '<td class="zalgo_td">' + zalgo_down[i] + '</td>\n';
}
html += '</tr>\n';
html += '</table>\n';
container.innerHTML = html;
}
// main shit
//---------------------------------------------------
function zalgo_textarea(id)
{
var p = document.getElementById(id);
var txt = p.value;
var newtxt = '';
for(var i=0; i<txt.length; i++)
{
if(is_zalgo_char(txt.substr(i, 1)))
continue;
var num_up;
var num_mid;
var num_down;
//add the normal character
newtxt += txt.substr(i, 1);
//options
if(document.getElementById('zalgo_opt_micro').checked)
{
num_up = rand(2);
num_mid = rand(1);
num_down = rand(2);
}
else if(document.getElementById('zalgo_opt_mini').checked)
{
num_up = rand(8);
num_mid = rand(2);
num_down = rand(8);
}
else if(document.getElementById('zalgo_opt_normal').checked)
{
num_up = rand(16) / 2 + 1;
num_mid = rand(6) / 2;
num_down = rand(16) / 2 + 1;
}
else if(document.getElementById('zalgo_opt_maxi').checked)
{
num_up = rand(64) / 4 + 3;
num_mid = rand(16) / 4 + 1;
num_down = rand(64) / 4 + 3;
}
else //Ultimate
{
num_up = zalgo_up.length;
num_mid = zalgo_mid.length;
num_down = zalgo_down.length;
}
if(document.getElementById('zalgo_opt_up').checked)
for(var j=0; j<num_up; j++)
newtxt += rand_zalgo(zalgo_up);
if(document.getElementById('zalgo_opt_mid').checked)
for(var j=0; j<num_mid; j++)
newtxt += rand_zalgo(zalgo_mid);
if(document.getElementById('zalgo_opt_down').checked)
for(var j=0; j<num_down; j++)
newtxt += rand_zalgo(zalgo_down);
}
//result is in nextxt, display that
//remove all children of lulz_container
var container = document.getElementById('lulz_container');
while(container.childNodes.length)
container.removeChild(container.childNodes[0]);
//build blocks for each line & create a <br />
var lines = newtxt.split("\n");
for(var i=0; i<lines.length; i++)
{
var n = document.createElement('text');
n.innerHTML = lines[i];
container.appendChild(n);
var nl = document.createElement('br');
container.appendChild(nl);
}
//done
}
/* ]]> */
</script>
</head>
<body>
<h1>Zalgo text generator</h1>
<span>2009 - tchouky </span>
<p></p>
<table id="zalgotable">
<tr>
<td id="lulz_container" style="BORDER-RIGHT: black 2px solid; PADDING-RIGHT: 50px; BORDER-TOP: black 2px solid; PADDING-LEFT: 50px; PADDING-BOTTOM: 50px; BORDER-LEFT: black 2px solid; PADDING-TOP: 50px; BORDER-BOTTOM: black 2px solid" width=550>
<p id="lulz"></p>
</td>
<td style="BORDER-RIGHT: black 2px solid; BORDER-TOP: black 2px solid; BORDER-LEFT: black 2px solid; BORDER-BOTTOM: black 2px solid" width=450>
<textarea id="zalgo_txt" style="FONT-FAMILY: Times New Roman" rows="13" cols="80">To invoke the hive-mind representing chaos.
Invoking the feeling of chaos.
With out order.
The Nezperdian hive-mind of chaos. Zalgo.
He who Waits Behind The Wall.
ZALGO!</textarea>
<form id="zalgo_form" action="">
<input id="zalgo_btn" onclick="zalgo_textarea('zalgo_txt');" type="button" value="HE COMES">
<input id="zalgo_ref" style="FLOAT: right" onclick="toggle('reference');" type="button" value="Toggle reference sheet">
<br />
<table>
<tr>
<td>
<input id="zalgo_opt_up" type="checkbox">fuck up going up<BR>
<input id="zalgo_opt_mid" type="checkbox" CHECKED>fuck up the middle<BR>
<input id="zalgo_opt_down" type="checkbox" CHECKED>fuck up going down<BR>
</td>
<td>
<input id="zalgo_opt_micro" type="radio" name="optval" CHECKED>micro fuck up<BR>
<input id="zalgo_opt_mini" type="radio" name="optval">mini fuck up<BR>
<input id="zalgo_opt_normal" type="radio" name="optval">normal fuck up<BR>
<input id="zalgo_opt_maxi" type="radio" name="optval">maxi fuck up<BR>
<input id="zalgo_opt_complete" type="radio" name="optval">U&#788;&#879;&#828;&#828;&#800;&#826;&#825;L&#774;&#786;&#773;&#868;&#855;T&#843;&#875;&#868;&#878;&#814;&#804;&#819;&#845;&#846;&#853;I&#779;&#784;&#773;&#855;&#868;&#843;&#768;&#841;&#853;M&#870;&#825;&#819;&#853;&#858;&#854;&#796;A&#771;&#831;&#811;&#854;&#825;T&#785;&#850;&#785;&#787;&#868;&#775;&#819;&#837;&#796;&#845;&#817;&#810;E&#850;&#839;&#814;&#858;&#814;&#798;&#854; &#780;&#788;&#777;&#828;&#853;F&#781;&#779;&#855;&#853;U&#855;&#859;&#877;&#819;&#805;C&#783;&#868;&#818;&#811;K&#776;&#844;&#874;&#777;&#875;&#872;&#852;&#796;&#798;&#811; &#855;&#842;&#788;&#830;&#798;&#815;U&#781;&#868;&#843;&#830;P&#876;&#835;&#779;&#768;&#793;&#813;&#858;<BR>
</td>
</tr>
</table>
</form>
<script type="text/javascript">
zalgo_textarea('zalgo_txt');
</script>
</TD>
</tr>
</TABLE>
<div id=reference style="DISPLAY: none">
<br />
<h2>Zalgo Characters Reference&gt;</h2>
<p id=zalgo_ref_tablex>
<script type="text/javascript">
draw_zalgo_table('zalgo_ref_tablex');
</script>
</p>
</div>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment