Guest User

Untitled

a guest
Oct 19th, 2017
242
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 51.21 KB | None | 0 0
  1. <html>
  2.  
  3.     <head>
  4.         <meta charset="UTF-8">
  5.         <title> News Gnerator </title>
  6.         <style>
  7.            
  8.             h2 {  
  9.                left: 10px;
  10.                width: 650px;
  11.                color: #223366;
  12.                font: 36px Helvetica, Sans-Serif;
  13.                letter-spacing: -1px;  
  14.             }
  15.            
  16.             .title {
  17.                 width:100%;
  18.                 margin-left: 14px;
  19.                 margin-bottom: 4px;
  20.                 color: #FFFFFF;
  21.                 font: 62px Impact, Charcoal, sans-serif;
  22.             }
  23.            
  24.             p {
  25.                color: #223366;
  26.                font: 18px Helvetica, Sans-Serif;
  27.             }
  28.            
  29.             a:link {
  30.                 text-decoration: none;
  31.             }
  32.  
  33.             a:visited {
  34.                 text-decoration: none;
  35.             }
  36.  
  37.             a:hover {
  38.                 text-decoration: none;
  39.             }
  40.  
  41.             a:active {
  42.                 text-decoration: none;
  43.             }
  44.            
  45.             html, body {
  46.                 overflow-x: hidden;
  47.                 padding: 0px;
  48.                 margin: 0px;
  49.                 background-color: #FCFCFC;
  50.             }  
  51.            
  52.             li {
  53.                 margin-top:8px;
  54.                 padding-left: 1em;
  55.                 text-indent: -.7em;
  56.             }
  57.            
  58.             li:before {
  59.                 content: "• ";
  60.                 color: #bc0000;
  61.             }          
  62.  
  63.             .header {
  64.                 padding: 0px;
  65.                 margin: 0px;
  66.                 width: 100%;
  67.                 height:138px;
  68.                 background-color: #183653;
  69.                 border-bottom: 4px solid #bc0000;
  70.             }
  71.            
  72.             .logo {
  73.                 margin-bottom: 0px;
  74.                
  75.             }
  76.            
  77.             .image {
  78.                 float: left;
  79.                 margin-right: 25px;
  80.             }
  81.            
  82.             .smallPic {
  83.                 vertical-align: bottom;
  84.                 display: inline-block;
  85.                 margin-left: 10px;
  86.                 height:150px;
  87.             }
  88.            
  89.             .links {
  90.                 margin: 0px;
  91.                 padding: 0px;
  92.                 position: relative;
  93.                 left: 20px;
  94.                 margin-top: 0px;
  95.             }
  96.            
  97.             .link {
  98.                 margin-right: 36px;
  99.                 color: #FBFBFB;
  100.                 font: 16px Helvetica, Sans-Serif;
  101.             }
  102.            
  103.             .smallText {
  104.                 list-style: none;
  105.                 color: #223366;
  106.                 font: 11px Helvetica, Sans-Serif;
  107.             }
  108.             .smallGreyText {
  109.                 list-style: none;
  110.                 color: #888888;
  111.                 font: 13px Helvetica, Sans-Serif;
  112.             }      
  113.  
  114.             .wimg {
  115.                 position: relative;
  116.                 top:6px;
  117.                 right:8px;
  118.             }
  119.            
  120.             .rightText {
  121.                 margin-left: 10px;
  122.                 width: 144px;
  123.                 color: #223366;
  124.                 font: 11px Helvetica, Sans-Serif;
  125.             }
  126.             .rightTextLarge {
  127.                 margin-top: 0px;
  128.                 margin-bottom: 5px;
  129.                 margin-left: 10px;
  130.                 color: #223366;
  131.                 font: 18px Helvetica, Sans-Serif;
  132.             }          
  133.            
  134.             .page {
  135.                 width:650px;
  136.                 margin: 75px;
  137.                 display: inline-block;
  138.                 position: static;
  139.                 left:5%;
  140.             }
  141.            
  142.             .rightPage {
  143.                 vertical-align: bottom;
  144.                 margin-bottom: 100px;
  145.                 width: 400px;
  146.                 display:inline-block;
  147.                 height: 400px;
  148.             }
  149.            
  150.             .main {
  151.                 height: 100%;
  152.             }
  153.            
  154.            
  155.         </style>
  156.         <script>
  157.         var msg = new SpeechSynthesisUtterance();
  158.         var voices = window.speechSynthesis.getVoices();
  159. </script>
  160.     </head>
  161.  
  162.     <body>
  163.    
  164.         <!-- Gnerator! -->
  165.         <?php
  166.             //RATT GNERATOR LIB v0.002b
  167.            
  168.        
  169.             //get
  170.             $simpl=0;
  171.             if (isset($_GET["wobl"])){
  172.                 $simpl=1;
  173.             }
  174.        
  175.             //SQL stoff
  176.             $servername = "localhost";
  177.             $username = "gnerator";
  178.             $password = "bobman";
  179.             $dbname = "gnerator";
  180.  
  181.             $servername = "shovelpilecom.ipagemysql.com";
  182.             $username = "bobman";
  183.             $password = "bobman";
  184.             $dbname = "gnerator";          
  185.            
  186.  
  187.             // Create connection
  188.             //$conn = new mysqli($servername, $username, $password, $dbname);
  189.             // Check connection
  190.             //if ($conn->connect_error) {
  191.             //  die("uh oh Connection failed: " . $conn->connect_error);
  192.             //}
  193.            
  194.             $save_string=databaseWord("nouns");
  195.             $save_string2=databaseWord("nouns");
  196.             $save_string3=databaseWord("nouns");
  197.             $gnerator_save=0;
  198.             $gnerator_save2=0;
  199.             $gnerator_save3=0;
  200.             $ucf=0;
  201.             $an=0;
  202.             $plur=0;
  203.             $remS=0;
  204.            
  205.  
  206.    
  207.             //$example = $wordsApi->getRandomWords("verb", null, null, null, null, null, null, null, null, null, null, 1);
  208.             //$example=$wordApi->getRelatedWords("cat","synonym","false","20");
  209.             //print $example[0]->words[rand(0,count($example[0]->words)-1)];
  210.  
  211.             $cels=rand(-20,35);
  212.             $tmpCels=rand(1,10);
  213.             if ($tmpCels==1){$cels=rand(-70,70);}
  214.             $minutes=rand(2,60);
  215.             $hours=rand(2,48);
  216.             $days=rand(2,30);
  217.             $born=rand(1750,1990);
  218.             $baitNum=rand(2,40);
  219.             $tmpYear=rand(1,3);
  220.             if ($tmpYear==1) {$year=rand(1750,2016);}
  221.             if ($tmpYear==2) {$year=rand(1910,2016);}
  222.             if ($tmpYear==3) {
  223.                 $tmpYear2=rand(1,8);
  224.                 if ($tmpYear2==1) {$year=rand(1914,1918);}
  225.                 if ($tmpYear2==2) {$year=rand(1939,1945);}
  226.                 if ($tmpYear2==3) {$year=1453;}
  227.                 if ($tmpYear2==4) {$year="4 BC";}
  228.                 if ($tmpYear2==5) {$year=1492;}
  229.                 if ($tmpYear2==6) {$year=1776;}
  230.                 if ($tmpYear2==7) {$year=1848;}
  231.                 if ($tmpYear2==8) {$year=1865;}
  232.             }
  233.             $bornday=rand(1,30);
  234.             $bornmonth=get_month(rand(1,12));
  235.             $died=$born+rand(40,120);
  236.             $diedday=rand(1,30);
  237.             $diedmonth=get_month(rand(1,12));
  238.             $percent=rand(0,100)."%";
  239.             $lifetime="";
  240.             $was="was";
  241.             $gender=rand(1,2);
  242.             $items=array();
  243.            
  244.             $tmpAss=rand(1,6);
  245.             if ($tmpAss==1 || $tmpAss==2) {$assets=rand(0,10000); $rich=1;}
  246.             if ($tmpAss==3 || $tmpAss==4) {$assets=rand(0,100000); $rich=2;}
  247.             if ($tmpAss==5 || $tmpAss==6) {$assets=rand(0,10000000); $rich=3;}
  248.             if ($gender==1) {$she="he"; $male="male";}
  249.             if ($gender==2) {$she="she"; $male="female";}
  250.             if ($died>2016){$died=0;}
  251.             if ($died>0) {$lifetime="("."$bornday $bornmonth $born - $diedday $diedmonth $died".")";}
  252.             if ($died==0) {$lifetime="(born ".$born.")"; $was="is";}
  253.            
  254.            
  255.             //$lines=file('nouns.txt');
  256.             //for ($i=0; $i<count($lines);$i++){
  257.             //  $lines[$i]=rtrim($lines[$i]);
  258.             //}
  259.             //define data!
  260.             //"&an <b> &save &remS &random nouns1 && &save2 &remS &random nouns1 </b> is &an &load2 with &plur &load |part2"
  261.             $gnerator_data=array(
  262.                 array("debug_start","|recipe"),
  263.                 array("save","&save &random nouns2 &save2 &random nouns2 &save3 &random nouns3"),
  264.                 array("start","&ucf |person |known &' &ucf |slogan '& |does","&ucf |person |does","&ucf |person |examines |himself &, |confirms","|country |says it |did |countryDid","|location |business |orgAccused |racism |orgAction","|location |police |searching |person for |action","|police |baffled after |person |steals |obj","|person |accused |selling |drugs on |boat","|person says he |regrets |action","|person spends |time |action","|scientists |predict |prediction","|org |feelers how |republicans would react to |new |event","|person &: &' &ucf |quote &!'","|scientists find |result","|inventors |develop |new |objAdj |obj","|person |says &' &ucf |quote '&","|person |nearly |does","|picture","|person |gives |person |objAdj |obj from |country","|racism |thriving in |location","|doctor claims most |patients |straight by the time |doctor2","|person was |arrested yesterday for |action","|result according to |research |funded &load2 |company","There is no &save2 |event in &save |country &, says &load &'s top &load2 |company","|person |hurt after treating |sickness with |drugs instead of |medicine","|song - New single by |band out now!","&save2 |obj |thieves leave man's &load2 behind |after_discovering |it_is |objAdj","|recipe"),
  265.                
  266.                 array("does","can't name any |adj &load","|arrested |after |action","|sells |objAdj |obj","|hurt in accident involving |objAdj |obj","experiences |event","|inPocket |org","|eats |obj"),
  267.                 array("action","shooting at |citePerson","smuggling |loads of |drugs","|saying &' |quote '&","having |sex with |person","calling for |event","|killing |animal with |drugs","|stealing |objAdj |obj","|raising |children","conducting |illegalBusiness in |country","|forgetting to |feed his |animal","|feeding |person |amount |drugs","|playing &' &ucf |song '& while |action"),
  268.                 array("orgAction","|sells |statue |resembling |person","when |leader found |action","","causes |event"),
  269.                 array("confirms","confirms he |is &an |republican","|finds |objAdj |obj","|refuses change |opinion |event","his |bodypart is |whereIt"),
  270.                 array("countryDid","|invade |country in $year","kill |org |leader","|proclaim |person as |leader"),
  271.                 array("prediction","|tomorrow will bring |event","the |obj of |tomorrow will be |objAdj","|objAdj |obj is the |drugs of |tomorrow","The |pet of |tomorrow will be the |animal && |animal"),
  272.                 array("result","owning &save2 |obj |more |rewarding than |action","$percent of |republicans still |decided whether to |vote |person or |person","$percent of |republicans have |tried &save2 |drugs","&save2 |drugs |completely |harmless"),
  273.                 array("picture","This |pic blows my mind","This |pic of |person is amazing","$baitNum pictures |clickbait","Gallery of |adj photographs","this |adj |pic was discovered in |location","Amazing |pic of |objAdj |obj","marvel at this incredible historical |pic from $year","<font COLOR='#BC0000'>WARNING GRAPHIC IMAGE: </font> |horrible |accident |maims |person","New species of |animal (pictured) discovered. |scientists baffled."),
  274.                
  275.                 //person
  276.                 array("person","leave voter","Donald Trump","Hillary Clinton","Obama","Trump","Clinton","muslim","school shooter","Trumpite","crippled man","small dwarf","abomination of a man","woman","man","clown","hobo","self proclaimed &' &ucf |person '&","friend","my uncle","Bernie Sanders","|obj expert","tinder user","area man","|location man","gay |person","evil |person","Kim Jong Un","Anonymous informant let's just call him &' |obj '&","pope","televangelist","wall street banker","Alex Jones","|person supporter","Unabomber","|countrish man","|countrish |person","Andrew Breitbart","man on the street","|animal","Ted Cruz","tramp","Hugo Chavez","surgeon","&remS |drugs dealer","Xi Jinping","tankman","|org member","jesus christ |jesus |jesus |jesus","Mike Pence","God","salesman of |obj","Jill Stein","Gary Johnson","Ron Paul","Al Gore","Hillary &' &ucf |hillary '& Clinton","Rush Limbaugh","wealthy teen","pictured person","guy I met outside the office (pictured)","Putin","|countrish |leader |person","Noam Chomsky","|location mother","|location father","Donald &' &ucf |donald '& Trump","hitler","guy I like to call |person","|person impersonator","gay conversion therapist","netizen","reddit user","|fruit farmer","Boris Johnson","Marxist","that guy","anonymous whistleblower","Military Veteran","local DJ","|musician","Pepe the |animal","Zimbabwean financial minister","naked man","former child star"),
  277.                 array("republican","republican","democrat","demon","human","cool dude","bad motherfucker","&random nounsX","independent","kike","monster","jew","american","|obj vandal","man","|adj man","clown","immigrant","|animal"),
  278.                 array("republicans","republicans","democrats","thieves","rappers","vandals","&plur |republican","terrorists","midgets","|adj people","kikes","jews","a large part of the population of |country","public","racists","clowns","crabbers","terrorists","the left","liberals","|org","autists","Islamic State Fighters","netizens","pretty much the entire following of |person","immigrants","senators","|countrish |republicans","|animal handlers","chimney sweepers","celebrities","cops"),
  279.                 array("scientists","scientists","researchers","experts","boffins","oracles","futurologists","people","|republicans","studies","|location polls","polls"),
  280.                 array("inventors","inventors","scientists","researchers","|republicans","alchemists","engineers","boffins","|adj |inventors"),
  281.                
  282.                 //stoff
  283.                 array("accident","accident","mishap","disaster","misadventure"),
  284.                 array("after_discovering","after discovering","after finding out","because","after determining","when learning","after noticing"),
  285.                 array("animal","cat","dog","crow","crocodile","camel","horse","|fruit","goose","ostrich","turkey","|animal && |animal","goat","snake","pelican","frog","crab","hostage","&random nounsX","gecko","cow","kangaroo","beetle","gnome","human","bear","raccoon","duck","worm","tiger","clam","turtle","piglet"),
  286.                 array("arrested","arrested","jailed","caught","shot to death","incarcerated","under arrest","confined","detained","locked up","in chains","fined"),
  287.                 array("bodypart","pussy","nose","tit","butt","asshole","hair","neck","vulva","dick","cock","nipple","leg","tongue","eye","beard","head","chest","hand","penis","kidney"),
  288.                 array("box","box","barrel","container","bag","bucket","toilet","backpack"),
  289.                 array("applaud","applaud","condone","hate","like","forget","disregard","nod at","dislike","acknowledge","point to","approve of"),
  290.                 array("clickbait","that will blow your mind","you have never seen before","that will amaze your friends","of |person","from |country"),
  291.                 array("children","children","kids","offspring","&plur |animal"),
  292.                 array("cruel","cruel","unethical","fair","barbarous","brutal","heartless","depraved","compassionate"),
  293.                 array("completely","completely","totally","absolutely","effectively","pretty much","perfectly","utterly"),
  294.                 array("company","company","corporation","lobby","organisation","manufacturer","union","association","dealer","advocate","legalization campaigner","minister"),
  295.                 array("color","red","green","blue","violet","orange","black","white","grey","indigo","pink","turquoise","azure","brown","cyan","yellow"),
  296.                 array("decided","decided","undecided","not sure","dubious","indecisive","unconvinced","uncertain","open"),
  297.                 array("develop","develop","invent","discover","unearth","evolve","grow","cultivate","construct","dream up"),
  298.                 array("duet","duet","twins","|republicans","|obj"),
  299.                 array("doctor","doctor","gay conversion therapist","experimental surgeon","unemployed nurse","|certified |doctor","lactation educator","'Medical' doctor","doctor of philosophy","certified sports specialist","experimental masseuse","dentist","gynecologist","unlicensed |doctor","biologist","dr frankenstein","surgeon","man claiming to be &an |doctor"),
  300.                 array("doctor2","they commit suicide","they leave his office","he's done with them","they stop fighting back","they give in","the procedure is completed","the effects of the |drugs wear off","|time","their |bodypart is taken care of"),
  301.                 array("donald","the donald","agent orange","bratman","the human corncob","darth hater","hair fuhrer","k-mart ceasar","the angry cheeto","ghengis can't","the xenophobic sweet potato","prima donald","the white kayne","dire abby","the tanning bed warning label","tangerine jesus","the feral shouting meatball","the talking yam","mango mussolini","cinnamon hitler","cheeto benito","|donald |donald |donald","|donald |donald"),
  302.                 array("eat","eat","cook","ingest","snort","insert","use","inject"),
  303.                 array("eats","eats","boils","ingests","inserts","has |sex with"),
  304.                 array("failure","failure","success","misstep","implosion","misadventure","adventure","wreck","achievement","triumph","attainment"),
  305.                 array("feeding","force feeding","feeding","lending","supplying","handing","selling"),
  306.                 array("fondly","fondly","yearningly","affectionately","longingly"),
  307.                 array("forgetting","forgetting","remembering","failing to remember","not being able to"),
  308.                 array("fuck","fuck","cap","kill","love"),
  309.                 array("funded","funded by","conducted by","by","sponsored by"),
  310.                 array("fruit","peach","apple","banana","coconut","habanero","watermelon","meatloaf","pineapple","cucumber","eggplant","onion","springroll","marijuana","chocolate","pumpkin","wheat","maple-syrup","gherkin","bark"),
  311.                 array("gives","gives","sells","deals","hands"),
  312.                 array("grab","grab","pinch","clasp","slap","poke","fiddle","take"),
  313.                 array("feed","feed","pet","take care of","play with","remember","care for"),
  314.                 array("harmless","harmless","safe","safe for |animal consumption","digestible","kosher","non toxic","unobjectionable","unfit for |animal consumption"),
  315.                 array("her","her","him"),
  316.                 array("hillary","shillary","hildebeest","killary","defender of child rapists","wealth pirate","leader of the party of death","rotten","heil hillary","klinton","crooked hillary","wicked witch of the west wing","hilla the hun","robbery hillham","mrs. carpetbagger","saint hillary","hitlery","ILLary","McPresident","Wife of Dollar Bill","Commander-in-thief","the great pretender","|hillary |hillary |hillary","|hillary |hillary"),
  317.                 array("hold","hold","touch","kiss","see","feel","grip"),
  318.                 array("horrible","horrible","terrible","scary","bizzare","strange","awful","dreadful","gruesome"),
  319.                 array("hurt","hurt","killed","disfigured","harmed","maimed","mutilated","wounded","unhurt","suffers brain damage"),
  320.                 array("jesus","lamb of god","son of god","son of man","light of the world","son of david","last adam","saviour of |person","king of the jews","rabbi","the son","his only begotten son","the son of the father","his own son","wonderful","creator of |obj","|jesus |jesus","|jesus |jesus |jesus","jehovah","the lord of glory","my messenger"),
  321.                 array("known","&, known for wanting to","&, who wants to","&, famous for saying"),
  322.                 array("kissed","kissed","licked","ate","smooched","saw","touched"),
  323.                 array("new","new","new kind of","another type of","yet another","brand new","unheard of"),
  324.                 array("statue","statue","painting","piece of art","product","sculpture","|obj"),
  325.                 array("resembling","resembling","shaped like","similar to","named after","offending"),
  326.                 array("leader","leader","president","warlord","secretary","CEO","head","ruler","director","boss","worker","god emperor","|jesus","advisor","person of the year","dictator","consul"),
  327.                 array("illegalBusiness","illegal business","shady affairs","strange ritual","mysterious dealings","secretive negotiations","open transparent legal and ethical business"),
  328.                 array("is","is","is not"),
  329.                 array("invade","invade","have diplomatic relations with","have something to do with","attack"),
  330.                 array("inPocket","in pocket of","in cahoots with","paid off by","connected with"),
  331.                 array("it_is","it is","it is too","it's not","it is really","that it is way too","it to be quite"),
  332.                 array("time","$hours hours","$days days","$minutes minutes","a long time","afternoon","bathroom break","a while","all day","christmas","vacation"),
  333.                 array("regrets","regrets","does not regret","does not remember","apologizes for","admits to","approves of"),
  334.                 array("says","says","claims","asserts","affirms","proclaims","announces","discloses","reports","told by |person","admits"),
  335.                 array("did","did","did not","did in fact","did certainly not","did surely","did of course","did for a fact"),
  336.                 array("examines","smells","examines","searches","audits","checks","explores","inspects","investigates","probes","researches","screens","studies","appraises","takes stock of"),
  337.                 array("himself","himself","|person"),
  338.                 array("after","after","for","over"),
  339.                 array("maims","maims","disfigures","injures","mangles","crushes","kills","amuses"),
  340.                 array("metal","iron","steel","copper","bronze","boron","tin","lead","marble","aluminium","nickel","bismuth","cobalt","electrum","molybdochalkos","tumbaga","gallium","gold","indium","magnesium","mercury","silver","plutonium","potassium","rhodium","sodium","uranium","titanium","zinc","pewter"),
  341.                 array("medicine","medicine","antibiotics","|drugs","prescription drugs","exorcism","voodoo ritual"),
  342.                 array("more","more","less"),
  343.                 array("nearly","nearly","almost","barely","essentially","practically","virtually","pretty much"),
  344.                 array("natures","nature's","worlds","|country &'s"),
  345.                 array("orgAccused","previously accused of","known for","involved in","that had nothing whatsoever to do with"),
  346.                 array("opinion","opinion on","beliefs about","plans for","opposition to"),
  347.                 array("patients","patients","subjects","clients","applicants","patrons","fools","|republicans"),
  348.                 array("pic","picture","image","|adj |pic","painting","photograph","art","photo","print","panorama","beautiful picture"),
  349.                 array("raising","raising","rearing","breeding","nursing","nurturing","educating","fostering"),
  350.                 array("research","research","study","trials","analysis","investigation"),
  351.                 array("refuses","refuses to","does not want to","will not","will","is going to","will most likely","might","still wont"),
  352.                 array("rewarding","rewarding","fulfilling","profitable","fruitful","productive","satisfying","worthwhile","gainful","fun","doable"),
  353.                 array("tried","tried","experimented with","never |tried","smoked","ingested","used"),
  354.                 array("feelers","putting out feelers for","polling for","is trying to find out","is wondering","is investigating","tells us they know"),
  355.                 array("tomorrow","tomorrow","next year","next week","the future","next presidency","this century","the distant future"),
  356.                 array("too","too","not very","quite","all too","kind of"),
  357.                 array("pet","pet","companion","creature","cattle"),
  358.                 array("planet","the moon","mars","europa","pluto","jupiter"),
  359.                 array("predict","predict","say","forsee","conclude","envision","think","figure","guess","presume","forespeak"),
  360.                 array("proclaim","name","proclaim","announce","declare","deny"),
  361.                 array("baffled","baffled","stumped","amazed","befuddled","confused","dazed","dumbfounded","puzzled","floored","elated","indifferent"),
  362.                 array("saying","saying","proclaiming","exclaiming","blurting out","shouting","uttering","yelling","crying","stating"),
  363.                 array("steal","steal","drive off with","pilfer","kidnap","take","plagiarize","poach","snatch","make off with","take possession of"),
  364.                 array("steals","steals","drives off with","pilfers","kidnaps","takes","plagiarizes","poaches","snatches","makes off with","takes possession of"),
  365.                 array("stealing","stealing","snatching","acquiring","buying","creating","donating"),
  366.                 array("searching","searching for","looking for","hunting","pursuing","inspecting"),
  367.                 array("straight","straight","cured","healthy","in good condition","dead","completely |straight","free of |racism","done","normal","recovered","|adj"),
  368.                 array("strict","strict","rigorous","tough","oppressive"),
  369.                 array("titanic","titanic","great","wonderful","unexpected","ordinary","glorious","epic","nice enough"),
  370.                 array("thriving","thriving","on the rise","increasing","soon to be gone","is finally a thing in","now extinct","now illegal","legalized"),
  371.                 array("thieves","thieves","&& jackers","smugglers","robbers","burglars","bandits","muggers","swindlers"),
  372.                 array("playing","playing","singing","blasting","cranking out"),
  373.                 array("police","police","national guard","law enforcement","|republican","detective"),
  374.                 array("citePerson","&' &ucf |person '&","|person","|person"),
  375.                 array("tricking","tricking","misleading","deceiving","duping","hoodwinking","swindling","hoaxing"),
  376.                 array("accused","accused of","suspected of","found","sued for","denies accusations of","admits"),
  377.                 array("sells","sells","buys","gives away","steals","unearths","finds","reveals","releases"),
  378.                 array("finds","finds","unearths","discovers","stumbles upon"),
  379.                 array("again","again","for the first time","like |country","right now","next"),
  380.                 array("great","great","impressive","awesome","big","large","huge","immense","tremendous","jumbo","extravagant"),
  381.                 array("selling","selling","using","handling","making","cooking","dealing"),
  382.                 array("sex","sex","affair","baby","good times","coitus","'sexy time'","romantic dinner","fun night out","wild |drugs fueld night","deep conversation","emotional connection","family"),
  383.                 array("loads","loads","huge amount","small quantity","a few grams","boatload","barrel","legal amount","trunk full","a little bit","substantial amount","considerable amount","great amount","a dab","a nugget","frankly incredible amount","too much","a handful","totally insignificant number"),
  384.                 array("killing","killing","murdering","slaying","hitting","attacking","feeding","boiling"),
  385.                 array("vote","vote for","support","oppose","like","&random verbsX"),
  386.                 array("whatHappened","what happened","the events of","the lessons of","everything about","the memory of","the best year of my life,"),
  387.                 array("whereIt","where it belongs","at the place it is supposed to be","itching","|adj","still there","vaguely |obj like","as it should be"),
  388.                
  389.                 array("song","|fuck tha |police","|person &'s song","Smells like |adj spirit","somebody to &random verbsX","All you need is |drugs","Light my |obj","Anarchy in |country","Hotel |location","1000 dollar |obj","One for my baby (And One More for the |obj &)","Working Class |republican","Sympathy for the |animal","|person in the sky with diamonds","I |kissed &an |animal and I liked it","I want to |hold your |bodypart","|bodypart of the |animal"),              
  390.                 array("band","|musician","|band1"),
  391.                 array("musician","|mus1 |mus2"),
  392.                 array("mus1","Snoop","Katy","Kurt","David","Elvis","Bob","John","Jimi","Justin","Paul","Michael","Frank","Ludwig van","Neil","Lady","Ozzy","B.B.","Jay","Bruce","Taylor","Lil","Stewie"),
  393.                 array("mus2","King","Z","Osbourne","Springsteen","Gaga","Young","Beethoven","Sinatra","Jackson","McCartney","Cobain","Bieber","Hendrix","Dylan","Presley","Bowie","Dogg","Perry","Swift","Wayne","Wonder"),
  394.                 array("band1","The &plur |animal","Def |band2","Led |obj","The Rolling |band2","The |band2","|metal |band2","Radio && |bodypart","|drugs N' |drugs","|color Hot &plur |fruit","|color day","Van |band2","|color |band2","Sex &plur |band2"),
  395.                 array("band2","Leppard","Stones","Who","Sabbath","Maiden","Halen","Clash","Cure","Doors","Floyd","Pistol"),
  396.                
  397.                 array("recipe","recipe of the day: |meal","|person teaches us how to cook |meal &!","recipe: |meal","Learn to cook delicious |meal &!"),
  398.                 array("meal","|food with |food","|food and |food","|foodAdj |food","|food filled with |food","|food with a side of |food","|food and |drugs"),
  399.                 array("food","|countrish |food2","|food2 && |food2","|objAdj |food2","|foodAdj |food2","|ingredient |food2","|foodAdj |ingredient |food2","|foodAdj |ingredient","|ingredient and |ingredient |food2"),
  400.                 array("ingredient","lamb","|animal","|drugs","|fruit","pork","bacon","potato","chicken","garlic","shrimp","mushroom","rice","spaghetti","spinach","beef","pepperoni","|bodypart","diet coke","cheeto","cheese","vodka","human flesh","salmon","ramen noodle","bratwurst","milk","jello","marmite","herring"),
  401.                 array("foodAdj","baked","slow cooked","savoury","classic","stuffed","grilled","smoked","BBQ","alcoholic","sweet","pickled"),
  402.                 array("food2","|fruit","steak","lasagna","cookies","bread","chili","liquor","soup","pie","stew","sauce","sausage","casserole","loaf","dressing","meatballs","roast","pot","wok","sushi","burrito","hamburger","pizza","feast","cider","paste","powder"),
  403.                
  404.                 array("sickness","|si1 && |si2","|person &'s disease"),
  405.                 array("si1","neur","myos","arter","arthr","bronch","hepat","ovar","brain","|bodypart","thrombophleb","multiple scler","|drugs","lup"),
  406.                 array("si2","itis","otomia","osis","emia","ism"),
  407.                
  408.                 array("event","race war","nuclear war","war in |country","world peace","handing out of free |drugs","judgement of god","shortage of |drugs","childrens crusade","financial crash","|obj shortage","proletarian revolution","civil war","disease and famine","whatever |person wants","|org -- |org merger","climate change","Jihad against |country","consequence","|location protest","golden age of prosperity","wedding","internet censorship","tsunami","shopping spree","public outrage","boring event nobody else cares about","|animal stampede","brexit"),
  409.                 array("boat","boat","camping trip","air plane","small cart","|objAdj |boat","roof","train","vacation to |country","|drugs","recent trip to |country","|countrish soil"),
  410.                 array("objAdj","worlds biggest","tiny","very rare","brand new","fire proof","valuable","&random adjsX","secret","long forgotten","dangerous","exploding","mysterious","extra-sloppy","dank","splendid","boorish","eerie","fascinating","otherwordly","common","woefully outdated","|metal","sweet","expensive designer","|country &'s first"),
  411.                 array("adj","European","sharia","republican","democrat","libertarian","tiny","&random adjsX","yuuge","funny","badass","cool","autistic","erotic","halal","vegan","magnificient","ancient","modern","|animal like","dank","boorish","sophisticated","brave","inexperienced","superficial","free","fat","wacky","teen","clown ass","well known"),
  412.                 array("nationObj","laws","exports","taxes","&plur &random nounsX","lawns","borders","government","nuclear arsenal","immigrants"),
  413.                
  414.                 array("quote","|slogan","&plur &ucf |animal and &plur |animal &, |natures |duet","I |applaud |whatHappened $year","|grab |her by the |bodypart","|republicans are |too |strict about |racism","I |fondly remember the |event of $year","My |doctor tells me to |eat less |drugs","This is like the |event of $year &!","I did not have |sex with |person &!","&save3 |person is &an |adj &rhyme3 nouns2","|event will be &an |titanic |failure &!"),
  415.                 array("slogan","control our own &save |nationObj","kill the |republicans","make |country |great |again","Legalize |drugs &!","clean |location of |drugs &!","vote for |person &!","stop the |cruel treatment of &plur |animal &!"),
  416.                
  417.                 array("location","Oregon","NY","Miami Beach","Vegas","neighbourhood","|country","Utah","Texas","small town","rural |country","area","Arkansas","Beverly Hills","Compton","New Jersey","small town","Aleppo","Kentucky","tianmen square","kremlin","nebraska","Beijing","inner city","Elon Musk's base on |planet","Mt Everest","JFK Airport","Yangtze River","California","Paris, Texas","Leicester","Dimension 7"),
  418.                 array("country","America","The United States of America","Canada","Sweden","Libya","Iraq","Syria","Afghanistan","Mexico","Turkmenistan","China","Chaiyna","Russia","The Soviet Union","Poland","North Korea","The Democratic Peoples Republic of Korea","|location","Ottoman Empire","|obj && land","Egypt","heaven","angola","Scotland","Cuba","Japan","Kosovo","Country where |event regularly happens","The land of the |adj &, the home of the |adj &, |country","the land of the |adj |obj","The Lone Star State of Texas","australia","the land down under","burma","The UK"),
  419.                 array("countrish","english","american","syrian","|location","european","chinese","mexican","north korean","libyan","canadian","cambodian","German","Scottish","Russian","Sudanese","cuban","australian"),
  420.                
  421.                 array("org","ISIS","Democratic Party Establishment","GOP","United Nations","European Union","|country","Soviet Union","Taliban","Green Party","Vatican","Westboro Baptist Church","4chan","Communist International","|countrish National party","|obj lobby","the senate","United |obj Corporation Inc","wikileaks","NATO","Taliban Muhajideen","Russian Secret Service"),
  422.                 array("business","bakery shop","&random nounsX shop","Walmart","Mc Donalds","Casino","Abortion Clinic","Family Planning Center","Bank","|obj cafe"),
  423.                 array("racism","racism","excessive carbon emissions","terrorism","sponsoring |org","harboring |republicans","posession of |drugs","consensual sex","police violence","calling for |event","using the metric system","cat calling","abuse of |drugs","homosexuality","homophobia"),
  424.                
  425.                 array("obj","cupcake","&random nounsX","marijuana cigarette","assault rifle","voice recording of |person","dick butt","dongle","stamp","house","|adj |obj","|objAdj |obj","|animal","bow and arrow","poop","ketchup","bag of |drugs","cool leather jacket","&random nounsX","samsung 7","|fruit","fresco","|countrish |obj","|boat","|box of packing peanuts","rug","|countrish flag","thermostat","mop","towel","twister mat","soy sauce packet","lamp shade","wagon","unicycle","button","fork","bread loaf","purse","currywurst","drill press","mop","blanket","credit card","sandal","candy wrapper","sailboat","deodorant","toe ring","stop sign","tire swing","coaster","blouse","bowl","garden gnome","beard","throne","abortion pill","|animal cage","sun","dreams","&save |obj &rhyme nouns2","rubber |animal","sand paper","lotion","rune stone","sarcophagus","screw","leg warmer","|magicItem","|meal"),
  426.                 array("drugs","drugs","&random nounsX","marijuana","cocaine","firearms","illegal chemicals","anthrax","plutonium","prescription drugs","&load","&plur |obj","condoms","saws","pesticides","GMO foods","vaccines","porn","sand","MDMA","MSG","greasy food","PCP","comic books","collagen","smallpox spores","&plur |fruit","tax returns","informational material from |org","|animal shit","|animal &plur |bodypart","life sustaining nutrition","&plur |fruit","black beauties","smart pills","bath salts","stardust","blow","meth","crank","speed","molly","moon rocks","love drugs","scooby snacks","smack","brown sugar","skunk","laughing gas","ketamine","acid","yellow sunshine","ganja","purple haze","magic mushrooms","shrooms","oxycotin","ritalin","diet coke","spice","black mamba","vicodin","xanax","angel dust","rocket fuel","mescaline","ether","coca cola","viagra","glue","jenkem","cognac","roses","marmite"),
  427.                
  428.                
  429.                 array("magicItem","|mItem1 |mItem2","|mItem1 |mItem2 of |mItem3"),
  430.                 array("mItem1","|objAdj","flaming","lazy","titanforged","wonderous","magical","dark","holy"),
  431.                 array("mItem2","bastard sword","katana","long bow","plate mail","hat","helmet","shield","gauntlet","ring","necklace","war axe"),
  432.                 array("mItem3","the |obj","flaming","dreaming","the |animal","ice","magic","death","love","|racism","|sickness","|mItem3 |mItem4"),
  433.                 array("mItem4","+1","+2","+7","that is cursed"),
  434.                
  435.                 //links
  436.                 array("links","Videos","Politics","U.S.","Opinion","Business","Entertainment","Tech","Science","Health","Travel","Lifestyle","World","Radio","TV","|country","|event","|person","&random nounsX","|drugs","|obj news","|adj news","|racism","Gossip","Clickbait","|animal news","|sex","|location"),
  437.                
  438.                 //title
  439.                 array("title","|t1 |t2","The |t1","The Daily |t1","The |location |t1"),
  440.                 array("t1","|animal","|person","|country","|countrish","|drugs","Gnerator","|org"),
  441.                 array("t2","News","Today","Journal","Post","Observer","Tribune","Herald","Bulletin","Weekly","Mirror"),
  442.            
  443.                 array("breaking","breaking","this just in","breaking news","|event","good news","the |racism crisis"),
  444.             );
  445.        
  446.            
  447.             //image
  448.             $imagesDir = 'images/';
  449.             $images = glob($imagesDir . '*.{jpg,jpeg,png,gif}', GLOB_BRACE);
  450.             $randomImage = $images[array_rand($images)];       
  451.             $smallPics = array();
  452.             for ($jj=0;$jj<10;$jj++){
  453.                 $smallPics[$jj]=$images[array_rand($images)];
  454.             }
  455.             $wimagesDir = 'weather/';
  456.             $wimages = glob($wimagesDir . '*.{jpg,jpeg,png,gif}', GLOB_BRACE);
  457.             $randomwImage = $wimages[array_rand($wimages)];        
  458.            
  459.             for ($i=1;$i<2;$i++){
  460.                 if (isset($_GET["debug"])){
  461.                     $peom=start_gnerat("debug_start");
  462.                 }else{
  463.                     $saves=start_gnerat("save");
  464.                     $peom=ucwords(start_gnerat("start"));
  465.  
  466.                     $tmpRnd=rand(1,16);
  467.                     if ($tmpRnd==1){$peom="<font COLOR='#BC0000'>".strtoupper(start_gnerat("breaking")).": </font>".$peom;}
  468.                
  469.                 }
  470.                
  471.                
  472.                 //print the site!
  473.                 if ($simpl==0) {
  474.                    
  475.                     //echo "<div class='header'><img class='logo' src='logo.png'></img>";
  476.                     echo "<div class='header'><a href='/news/'><h2 class='title'>".strtoupper(start_gnerat("title"))."</h2></a>";
  477.                         echo "<p class='links'>";
  478.                             echo "<a class='link' href='/news/'><b>Home</b></a>";
  479.                             $tmpNum=rand(4,10);
  480.                             for ($rr=0;$rr<$tmpNum;$rr++){
  481.                                 echo "<a class='link' href='/news/'><b>".ucwords(start_gnerat("links"))."</b></a>";
  482.                             }
  483.                         echo "</p>";
  484.                     echo "</div>";
  485.                    
  486.                     echo "<div class='main'>";
  487.                    
  488.                         echo "<div class='page'>";
  489.                             echo "<h2><b>".$peom."<b></h2>";
  490.                             echo "<div><img class='image' src='".$randomImage."' width=397 height=270></img>";
  491.                                     echo "<hr><ul class='smallText'>";
  492.                                     for ($bb=0;$bb<5;$bb++){
  493.                                         echo "<li><b>".ucwords(start_gnerat("start"))."</b></li>";
  494.                                     }
  495.                                     echo "</ul>";
  496.                             echo "</div>";
  497.                         echo "</div>"; 
  498.  
  499.                         echo "<div class='rightPage'>";
  500.                             echo "<p class='rightTextLarge' align='right'><img class='wimg' src='".$randomwImage."'></img>".$cels."°C &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font class='smallGreyText'>".ucwords(start_gnerat("location"))."</font></p>";
  501.                             echo "<hr><p class='rightTextLarge'>".ucwords(start_gnerat("adj"))." News:</p>";
  502.                             for ($oo=0;$oo<6;$oo++){
  503.                                 echo "<div class='smallPic'><img src='".$smallPics[$oo]."' width=144 height=81></img>";
  504.                                 echo "<p class='rightText'><b>".ucwords(start_gnerat("start"))."</b></p></div>";
  505.                             }
  506.                         echo "</div>";
  507.                     echo "</div>";
  508.                 }
  509.  
  510.             }
  511.  
  512.            
  513.             //money
  514.             function money($tmp)
  515.             {
  516.                 if ($tmp<1000) {$tmp=round($tmp,-1);}
  517.                 if ($tmp>1000) {$tmp=round($tmp,-2);}
  518.                 if ($tmp>10000) {$tmp=round($tmp,-3);}
  519.                 if ($tmp>100000) {$tmp=round($tmp,-4);}
  520.                 if ($tmp>1000000) {$tmp=round($tmp,-5);}
  521.  
  522.                
  523.                 return $tmp;
  524.                
  525.             }
  526.            
  527.             //get a random month
  528.             function get_month($tmp)
  529.             {
  530.                 if ($tmp=1) {return "January";}
  531.                 if ($tmp=2) {return "February";}
  532.                 if ($tmp=3) {return "Mars";}
  533.                 if ($tmp=4) {return "April";}
  534.                 if ($tmp=5) {return "May";}
  535.                 if ($tmp=6) {return "June";}
  536.                 if ($tmp=7) {return "July";}
  537.                 if ($tmp=8) {return "August";}
  538.                 if ($tmp=9) {return "September";}
  539.                 if ($tmp=10) {return "October";}
  540.                 if ($tmp=11) {return "November";}
  541.                 if ($tmp=12) {return "December";}
  542.                
  543.             }
  544.            
  545.            
  546.             //find a rhyme
  547.             function rhyme($tmpString, $wordlist){
  548.                 global $conn;
  549.                 $num=3;
  550.                 $tmpEnd=substr($tmpString,-$num);
  551.                 if (strlen($tmpEnd)==2){
  552.                     $num=2;
  553.                 }
  554.                 //ix
  555.                 if ($tmpEnd=="six" || $tmpEnd=="ix"){$tmpEnd="iks";}
  556.                 //ead
  557.                 if ($tmpEnd=="ead"){
  558.                     $a=rand(1,4);
  559.                     if ($a==1){$tmpEnd="ed";$num=2;}
  560.                     if ($a==2){$tmpEnd="eed";$num=3;}
  561.                 }
  562.                 //eap
  563.                 if ($tmpEnd=="eap"){
  564.                     $a=rand(1,4);
  565.                     if ($a==1){$tmpEnd="ep";$num=2;}
  566.                     if ($a==2){$tmpEnd="eep";$num=3;}
  567.                 }              
  568.                 //$sql="SELECT word FROM $wordlist WHERE RIGHT(word, $num) = '$tmpEnd' ORDER BY RAND() LIMIT 1";
  569.                 //$result = $conn->query($sql);
  570.                 //if ($result->num_rows > 0) {
  571.                 //  $row = $result->fetch_array(MYSQLI_NUM);
  572.                 //  return $row[0];
  573.                 //} else {
  574.                     //echo $sql."</br>";
  575.                     //echo "0 rows returned.";
  576.                 //  return databaseWord($wordlist);
  577.                 //}    
  578.                 return "wobl!"
  579.             }
  580.             //get random word
  581.             function databaseWord($wordlist){
  582.                 global $conn;
  583.                
  584.                 /*$sql="SELECT word FROM $wordlist ORDER BY RAND() LIMIT 1";
  585.                 $result = $conn->query($sql);
  586.                 if ($result->num_rows > 0) {
  587.                     $row = $result->fetch_array(MYSQLI_NUM);
  588.                    
  589.                     //verb?
  590.                     if ($wordlist=="verbs" || $wordlist=="verbs1" || $wordlist=="verbs2" || $wordlist=="verbs3" || $wordlist=="verbs4"){
  591.                         //check for ing
  592.                         $tmpEnd2=substr(strtolower($row[0]), -3);
  593.                         if ($tmpEnd2=="ing"){
  594.                             //print "</br>-- ".$row[0];
  595.                             $row[0]=databaseWord($wordlist);
  596.                         }
  597.                         //remove ed
  598.                         $tmpEnd=substr(strtolower($row[0]), -2);
  599.                         if ($tmpEnd=="ed"){
  600.                             $row[0]=substr($row[0],0,-2);
  601.                         }
  602.                         //remove s and return
  603.                         return remove_s($row[0]);  
  604.                     //not verb
  605.                     }else{
  606.                         return $row[0];
  607.                     }
  608.                        
  609.                 } else {
  610.                     //echo $sql."</br>";
  611.                     //echo "0 rows returned.";
  612.                     return "fuck";
  613.                 }          
  614.                 */
  615.                 return "RANDOM WORDL!"
  616.             }          
  617.                    
  618.             //here we start to gnerat!
  619.             function start_gnerat($start_point){
  620.                 global $gnerator_data;
  621.                 global $save_string;   
  622.                 global $save_string2;
  623.                 global $save_string3;
  624.                 global $gnerator_save;
  625.                 global $gnerator_save2;
  626.                 global $gnerator_save3;
  627.                 global $ucf;
  628.                 global $an;
  629.                 global $plur;
  630.                 global $remS;
  631.                 global $fullname;
  632.                 $gnerator_result="";
  633.                 $explode_array=null;
  634.                
  635.                 //find start point
  636.                 for ($i=0;$i<count($gnerator_data);$i++){
  637.                     if ($gnerator_data[$i][0]==$start_point){
  638.                        
  639.                         //explode it and loop it word for word
  640.                         $explode_array=explode(" ",$gnerator_data[$i][rand(1,count($gnerator_data[$i])-1)]);
  641.                        
  642.                         for ($z=0;$z<count($explode_array);$z++){
  643.                             //link links to somwhere!
  644.                             if (startsWith($explode_array[$z],"|")){
  645.                                 $temp_word=str_replace("|","",$explode_array[$z]);
  646.                                 $gnerator_result=$gnerator_result.start_gnerat($temp_word);
  647.                             }
  648.                             //random old age
  649.                             else if ($explode_array[$z]=="&old"){
  650.                                 $gnerator_result=$gnerator_result.rand(50,115)." ";
  651.                             }
  652.                             //random percent
  653.                             else if ($explode_array[$z]=="&percent"){
  654.                                 $gnerator_result=$gnerator_result.rand(0,100)." ";
  655.                             }
  656.                             //fullname
  657.                             else if ($explode_array[$z]=="&fullname"){
  658.                                 $gnerator_result=$gnerator_result.$fullname." ";
  659.                             }
  660.                             //rhyme
  661.                             else if ($explode_array[$z]=="&rhyme" || $explode_array[$z]=="&rhyme2" || $explode_array[$z]=="&rhyme3"){
  662.                                 //next part
  663.                                 $wordlist=$explode_array[$z+1];
  664.                                 $explode_array[$z+1]="";
  665.                                
  666.                                 $rhyme1=rhyme($save_string,$wordlist);
  667.                                 $rhyme2=rhyme($save_string2,$wordlist);
  668.                                 $rhyme3=rhyme($save_string3,$wordlist);
  669.                                 //an?
  670.                                 if ($an==1){
  671.                                     $an=0;
  672.                                     if ($explode_array[$z]=="&rhyme"){$gnerator_result=$gnerator_result.get_pref($rhyme1)." ";}
  673.                                     if ($explode_array[$z]=="&rhyme2"){$gnerator_result=$gnerator_result.get_pref($rhyme2)." ";}
  674.                                     if ($explode_array[$z]=="&rhyme3"){$gnerator_result=$gnerator_result.get_pref($rhyme3)." ";}
  675.                                 }  
  676.                                 //save?
  677.                                 if ($gnerator_save==1){
  678.                                     if ($explode_array[$z]=="&rhyme"){$save_string=$rhyme1;}
  679.                                     if ($explode_array[$z]=="&rhyme2"){$save_string=$rhyme2;}
  680.                                     if ($explode_array[$z]=="&rhyme3"){$save_string=$rhyme3;}
  681.                                     $gnerator_save=0;
  682.                                 }
  683.                                 //save2?
  684.                                 if ($gnerator_save2==1){
  685.                                     if ($explode_array[$z]=="&rhyme"){$save_string2=$rhyme1;}
  686.                                     if ($explode_array[$z]=="&rhyme2"){$save_string2=$rhyme2;}
  687.                                     if ($explode_array[$z]=="&rhyme3"){$save_string2=$rhyme3;}
  688.                                     $gnerator_save2=0;
  689.                                 }  
  690.                                 //save3?
  691.                                 if ($gnerator_save3==1){
  692.                                     if ($explode_array[$z]=="&rhyme"){$save_string3=$rhyme1;}
  693.                                     if ($explode_array[$z]=="&rhyme2"){$save_string3=$rhyme2;}
  694.                                     if ($explode_array[$z]=="&rhyme3"){$save_string3=$rhyme3;}
  695.                                     $gnerator_save3=0;
  696.                                 }                              
  697.                                
  698.                                 if ($explode_array[$z]=="&rhyme") {$gnerator_result=$gnerator_result.$rhyme1." ";}
  699.                                 if ($explode_array[$z]=="&rhyme2") {$gnerator_result=$gnerator_result.$rhyme2." ";}
  700.                                 if ($explode_array[$z]=="&rhyme3") {$gnerator_result=$gnerator_result.$rhyme3." ";}
  701.                             }  
  702.                             //random
  703.                             else if ($explode_array[$z]=="&random"){
  704.                                 //next part
  705.                                 $wordlist=$explode_array[$z+1];
  706.                                 $explode_array[$z+1]="";
  707.                                
  708.                                 //nounsX
  709.                                 if ($wordlist=="nounsX"){
  710.                                     $tmpRnd=rand(1,3);
  711.                                     $wordlist="nouns".$tmpRnd;
  712.                                 }
  713.                                 //adjsX
  714.                                 if ($wordlist=="adjsX"){
  715.                                     $tmpRnd=rand(1,3);
  716.                                     $wordlist="adjs".$tmpRnd;
  717.                                 }      
  718.                                 //verbsX
  719.                                 if ($wordlist=="verbsX"){
  720.                                     $tmpRnd=rand(1,3);
  721.                                     $wordlist="verbs".$tmpRnd;
  722.                                 }                                  
  723.                                
  724.                                 $tmpRandom=databaseWord($wordlist);
  725.                                 //an?
  726.                                 if ($an==1){
  727.                                     $an=0;
  728.                                     $gnerator_result=$gnerator_result.get_pref($tmpRandom)." ";
  729.                                 }  
  730.                                 //plur?
  731.                                 if ($plur==1){
  732.                                     $plur=0;
  733.                                     $tmpRandom=get_plur($tmpRandom);
  734.                                 }  
  735.                                 //remS?
  736.                                 if ($remS==1){
  737.                                     $remS=0;
  738.                                     $tmpRandom=remove_s($tmpRandom);
  739.                                 }                              
  740.                                 //save?
  741.                                 if ($gnerator_save==1){
  742.                                     $save_string=$tmpRandom;
  743.                                     $gnerator_save=0;
  744.                                 }
  745.                                 //save2?
  746.                                 if ($gnerator_save2==1){
  747.                                     $save_string2=$tmpRandom;
  748.                                     $gnerator_save2=0;
  749.                                 }  
  750.                                 //save3?
  751.                                 if ($gnerator_save3==1){
  752.                                     $save_string3=$tmpRandom;
  753.                                     $gnerator_save3=0;
  754.                                 }                                  
  755.                                
  756.                                 //ucf?
  757.                                 if ($ucf==1){
  758.                                     $ucf=0;
  759.                                     $tmpRandom=ucfirst($tmpRandom);
  760.                                 }  
  761.                                 $gnerator_result=$gnerator_result.$tmpRandom." ";
  762.                             }
  763.                             //save
  764.                             else if ($explode_array[$z]=="&save"){
  765.                                 $gnerator_save=1;
  766.                             }
  767.                             //load
  768.                             else if ($explode_array[$z]=="&load"){
  769.                                 if ($an==1){
  770.                                     $an=0;
  771.                                     $gnerator_result=$gnerator_result.get_pref($save_string)." ";
  772.                                 }                              
  773.                                 if ($plur==1){
  774.                                     $plur=0;
  775.                                     $gnerator_result=$gnerator_result.get_plur($save_string)." ";
  776.                                 }else{
  777.                                     $gnerator_result=$gnerator_result.$save_string." ";
  778.                                 }
  779.                             }
  780.                             //save2
  781.                             else if ($explode_array[$z]=="&save2"){
  782.                                 $gnerator_save2=1;
  783.                             }
  784.                             //save3
  785.                             else if ($explode_array[$z]=="&save3"){
  786.                                 $gnerator_save3=1;
  787.                             }                          
  788.                             //save2now
  789.                             else if ($explode_array[$z]=="&save2now"){
  790.                                 $save_string2=$explode_array[$z+1];
  791.                                 $explode_array[$z+1]="";
  792.                                 $explode_array[$z]="";
  793.                                
  794.                             }
  795.                             //load2
  796.                             else if ($explode_array[$z]=="&load2"){
  797.                                 if ($an==1){
  798.                                     $an=0;
  799.                                     $gnerator_result=$gnerator_result.get_pref($save_string2)." ";
  800.                                 }                                  
  801.                                 if ($plur==1){
  802.                                     $plur=0;
  803.                                     $gnerator_result=$gnerator_result.get_plur($save_string2)." ";
  804.                                 }else{
  805.                                     $gnerator_result=$gnerator_result.$save_string2." ";
  806.                                 }
  807.                             }
  808.                             //load3
  809.                             else if ($explode_array[$z]=="&load3"){
  810.                                 if ($an==1){
  811.                                     $an=0;
  812.                                     $gnerator_result=$gnerator_result.get_pref($save_string3)." ";
  813.                                 }                                  
  814.                                 if ($plur==1){
  815.                                     $plur=0;
  816.                                     $gnerator_result=$gnerator_result.get_plur($save_string3)." ";
  817.                                 }else{
  818.                                     $gnerator_result=$gnerator_result.$save_string3." ";
  819.                                 }
  820.                             }                          
  821.                             //ucf
  822.                             else if ($explode_array[$z]=="&ucf"){
  823.                                 $ucf=1;
  824.                             }
  825.                             //remS
  826.                             else if ($explode_array[$z]=="&remS"){
  827.                                 $remS=1;
  828.                             }
  829.                             //an
  830.                             else if ($explode_array[$z]=="&an"){
  831.                                 $an=1;
  832.                             }      
  833.                             //plur
  834.                             else if ($explode_array[$z]=="&plur"){
  835.                                 $plur=1;
  836.                             }                              
  837.                             //normal word just add to output
  838.                             else {
  839.                                 //an?
  840.                                 if ($an==1){
  841.                                     $an=0;
  842.                                     $gnerator_result=$gnerator_result.get_pref($explode_array[$z])." ";
  843.                                 }
  844.                                 //plur?
  845.                                 if ($plur==1){
  846.                                     $plur=0;
  847.                                     $explode_array[$z]=get_plur($explode_array[$z]);
  848.                                 }  
  849.                                 //remS?
  850.                                 if ($remS==1){
  851.                                     $remS=0;
  852.                                     $explode_array[$z]=remove_s($explode_array[$z]);
  853.                                 }                                  
  854.                                
  855.                                 //ucf?
  856.                                 if ($ucf==1){
  857.                                     $ucf=0;
  858.                                     $gnerator_result=$gnerator_result.ucfirst($explode_array[$z])." ";
  859.                                 }                          
  860.                                 else{
  861.                                     $gnerator_result=$gnerator_result.$explode_array[$z]." ";
  862.                                 }
  863.                                 //save?
  864.                                 if ($gnerator_save==1){
  865.                                     $save_string=$explode_array[$z];
  866.                                     $gnerator_save=0;
  867.                                 }
  868.                                 //save2?
  869.                                 if ($gnerator_save2==1){
  870.                                     $save_string2=$explode_array[$z];
  871.                                     $gnerator_save2=0;
  872.                                 }  
  873.                                 //save3?
  874.                                 if ($gnerator_save3==1){
  875.                                     $save_string3=$explode_array[$z];
  876.                                     $gnerator_save3=0;
  877.                                 }                                  
  878.                             }
  879.                         }
  880.                     }
  881.                 }
  882.                
  883.                 $gnerator_result=str_replace("  &<","",$gnerator_result);
  884.                 $gnerator_result=str_replace("  &;",";",$gnerator_result);
  885.                 $gnerator_result=str_replace("  &?","?",$gnerator_result);
  886.                 $gnerator_result=str_replace("  &.",".",$gnerator_result);
  887.                 $gnerator_result=str_replace("  &,",",",$gnerator_result);
  888.                 $gnerator_result=str_replace("  &!","!",$gnerator_result);
  889.                 $gnerator_result=str_replace("  &'s","'s",$gnerator_result);
  890.                 $gnerator_result=str_replace(" &;",";",$gnerator_result);
  891.                 $gnerator_result=str_replace(" &:",":",$gnerator_result);              
  892.                 $gnerator_result=str_replace(" &.",".",$gnerator_result);
  893.                 $gnerator_result=str_replace(" &!","!",$gnerator_result);
  894.                 $gnerator_result=str_replace(" &?","?",$gnerator_result);
  895.                 $gnerator_result=str_replace(" &,",",",$gnerator_result);
  896.                 $gnerator_result=str_replace(" &'s","'s",$gnerator_result);
  897.                 $gnerator_result=str_replace("&' "," '",$gnerator_result);
  898.                 $gnerator_result=str_replace(" '&","' ",$gnerator_result);
  899.                 $gnerator_result=str_replace("(& ","(",$gnerator_result);
  900.                 $gnerator_result=str_replace(" &)",")",$gnerator_result);              
  901.                 $gnerator_result=str_replace("  && ","",$gnerator_result);
  902.                 $gnerator_result=str_replace(" && ","",$gnerator_result);  
  903.                 $gnerator_result=str_replace(" -- ","-",$gnerator_result);
  904.                 $gnerator_result=str_replace("&tab","&nbsp&nbsp&nbsp&nbsp&nbsp",$gnerator_result);             
  905.                 return $gnerator_result;
  906.             }
  907.            
  908.             //String Start/End char functions.
  909.             function startsWith($haystack, $needle) {
  910.                 return $needle === "" || strrpos($haystack, $needle, -strlen($haystack)) !== FALSE;
  911.             }
  912.             function endsWith($haystack, $needle) {
  913.                 return $needle === "" || (($temp = strlen($haystack) - strlen($needle)) >= 0 && strpos($haystack, $needle, $temp) !== FALSE);
  914.             }
  915.        
  916.             //a/an
  917.             function get_pref($tmpTxt)
  918.             {
  919.                 $tmpStart=substr(strtolower($tmpTxt),0,1);
  920.                 if ($tmpStart=="a" || $tmpStart=="e" || $tmpStart=="i" || $tmpStart=="o" || $tmpStart=="u" || $tmpStart=="y"){
  921.                     return "an";
  922.                 }else{
  923.                     return "a";
  924.                 }
  925.             }
  926.             //plural
  927.             function get_plur($tmpTxt){
  928.                 $tmpEnd=substr(strtolower($tmpTxt), -1);
  929.                 if ($tmpEnd=="x" || $tmpEnd=="z" || $tmpEnd=="ch" || $tmpEnd=="sh"){
  930.                     return $tmpTxt."es";
  931.                 }else if ($tmpEnd=="y"){
  932.                     return substr($tmpTxt,0,-1)."ies";
  933.                 //ending with s just assume already plur and return.
  934.                 }else if ($tmpEnd=="s"){
  935.                         return $tmpTxt;
  936.                 }else{
  937.                     return $tmpTxt."s";
  938.                 }
  939.             }
  940.             //remove s
  941.             function remove_s($tmpTxt){
  942.                 $tmpEnd=substr(strtolower($tmpTxt), -1);
  943.                 $tmpEnd2=substr(strtolower($tmpTxt), -3);
  944.                 if ($tmpEnd=="s"){
  945.                         return substr($tmpTxt,0,-1);
  946.                 }else{                 
  947.                     return $tmpTxt;
  948.                 }
  949.             }  
  950.            
  951.        
  952.        
  953.         $output_array=str_split($peom,99);
  954.         $output_len=count($output_array);
  955.  
  956.         $text_speed=1; $a=rand(1,70); if ($a==1){$text_speed=0;}
  957.         $text_pitch=0; $a=rand(1,70); if ($a==1){$text_pitch=2;}
  958.         ?>
  959.    
  960.  
  961.     <script>   
  962.         document.addEventListener("DOMContentLoaded", function(event) {
  963.             msg = new SpeechSynthesisUtterance();
  964.             voices = window.speechSynthesis.getVoices();
  965.         setTimeout(function () {
  966.             msg.voice = voices[<?php echo rand(1,10);?>]; // Note: some voices don't support altering params
  967.             msg.voiceURI = 'native';
  968.             msg.volume = 1; // 0 to 1
  969.             msg.rate = <?php echo $text_speed;?>; // 0.1 to 10
  970.             msg.pitch = <?php echo $text_pitch;?>; //0 to 2
  971.             msg.lang = 'en-US';
  972.             messages = [<?php for ($i=0;$i<$output_len;$i++){echo '"'.$output_array[$i].'"'; if ($i<$output_len-1){echo ',';} }?>];
  973.             var messageNumber = 0;
  974.             msg.text = messages[messageNumber];
  975.             msg.onend = function(e) {
  976.               console.log('Finished in ' + event.elapsedTime + ' seconds.');
  977.               messageNumber = messageNumber + 1;
  978.               msg.text = messages[messageNumber];
  979.               msg.voice = voices[<?php echo rand(1,10);?>]; // Note: some voices don't support altering params
  980.               msg.voiceURI = 'native';
  981.               msg.rate = <?php echo $text_speed;?>; // 0.1 to 10
  982.               msg.pitch = <?php echo $text_pitch;?>; //0 to 2
  983.               msg.lang = 'en-US';
  984.               msg.volume = 1; // 0 to 1
  985.               if (msg.text=="pause") {
  986.                 msg.volume = 0;
  987.               } else {
  988.               }
  989.               if (messageNumber < messages.length) {
  990.                 speechSynthesis.speak(msg);
  991.               }
  992.             };
  993.             //speechSynthesis.speak(msg);
  994.             }, 1000);  
  995.             });
  996.     </script>
  997.    
  998.     </body>
  999.  
  1000. <html>
Add Comment
Please, Sign In to add comment