My script seems to be broken jQuery/JavaScript

My script seems to be broken jQuery/JavaScript

Hi guys, First post here.

So here is my problem, This was working perfectly, but after about some time it stopped working, I don't know what I changed and it is giving me the biggest headache I have ever had. What is supposed to happen is the JavaScript is supposed to call data and write it into its corresponding field. It has a timer of which it displays the different strings on the web portal.

I call jQuery  CDM from Microsofts source in the beginning of my site in the header:
  1. <script src="http://ajax.aspnetcdn.com/ajax/jQuery/jquery-1.12.1.min.js"></script>

Then here is the script that is supposed to replace the strings.


  1.     <div id="Intro" onclick="showMOTD();">
         
              <pre><div id="innerPreDiv"><span class="lightText">guest@text.text:$ </span><span class="lightText">more random text<br></span><span class="lightText">WĘlcoϻe to myramdomsite </span><span class="lightText">AAAAAAAAAAAAAAAAA<br></span><span class="lightText">randomtext</span><span class="lightText">anotherrandomstring</span><span class="lightText">anotherrandomstring<br></span><span class="lightText">stringscarryon<br><br></span><span class="darkText"># somanystrings<br></span><span class="darkText">kernel died (signal 0, exit 11)<br></span><span class="darkText">Automatic reset in 3 seconds.</span><span class="darkText">....</span><span class="lightText"><br><br>root@text.text ~ # </span><span></span><span class="lightText">id<br></span><span class="lightText">uid=0(root) gid=0(root) groups=0(root)<br></span><span class="lightText">root@text.text ~ # </span><span class="lightText">./motd &amp;<br></span><span class="lightText">root@text.text ~ # </span></div></pre>


  1. #This part is where I call a file called dynatexer:
            <script type="text/javascript" src="/uploads_dynatexer.min.js"></script>


  1. #This part is where the text was written in initially - Changed the output a bit now
  2. #This is how it is in my HTML code.
            <script type="text/javascript">
             
                  var alreadyShown = 0;
             
                jQuery(document).ready(function() {
                    jQuery("#innerPreDiv").dynatexer({
                        loop: 1,
                        content: [
                              {
                                animation: 'additive',
                                delay: 0,
                                placeholder: '<span class="lightText">',
                                render_strategy: 'text-one-shot',
                                items: "guest@text.text$ "
                            },
                            {
                                animation: 'additive',
                                delay: 175,
                                placeholder: '<span class="lightText">',
                                render_strategy: 'text-by-char',
                                items: "./r00tme\n"
                            },
                              {
                                animation: 'additive',
                                delay: 500,
                                placeholder: '<span class="lightText">',
                                render_strategy: 'text-one-shot',
                                items: "Welcom to myramdomsite"
                            },
                            {
                                  animation: 'additive',
                                  delay: 10,
                                  placeholder: '<span class="lightText">',
                                  render_strategy: 'text-by-char',
                                  items: "AAAAAAAAAAAAAAAAA"
                            },
                              {
                                animation: 'additive',
                                delay: 250,
                                placeholder: '<span class="lightText">',
                                render_strategy: 'text-one-shot',
                                items: "randomtext"
                            },
                              {
                                animation: 'additive',
                                delay: 250,
                                placeholder: '<span class="lightText">',
                                render_strategy: 'text-one-shot',
                                items: "randoms"
                            },
                            {
                                animation: 'additive',
                                delay: 25,
                                placeholder: '<span class="lightText">',
                                render_strategy: 'text-by-char',
                                items: "randomtexttt"
                            },
                              {
                                animation: 'additive',
                                delay: 250,
                                placeholder: '<span class="lightText">',
                                render_strategy: 'text-one-shot',
                                items: "Segmentation fault"
                            },
                         
                              {
                                animation: 'additive',
                                delay: 500,
                                placeholder: '<span class="darkText">',
                                render_strategy: 'text-one-shot',
                                items: "# random text Segmentation fault\n"
                            },
                            {
                                animation: 'additive',
                                delay: 500,
                                placeholder: '<span class="darkText">',
                                render_strategy: 'text-one-shot',
                                items: "kernel died (signal 0, exit 11)\n"
                            },
                            {
                                animation: 'additive',
                                delay: 500,
                                placeholder: '<span class="darkText">',
                                render_strategy: 'text-one-shot',
                                items: "Automatic reset in 3 seconds."
                               },
                            {
                                animation: 'additive',
                                delay: 500,
                                placeholder: '<span class="darkText">',
                                render_strategy: 'text-by-char',
                                items: "...."
                               },
                         
                               {
                                animation: 'additive',
                                delay: 200,
                                placeholder: '<span class="lightText">',
                                render_strategy: 'text-one-shot',
                                items: "\n\nroot@text.text ~ # "
                            },
                              {
                                  delay: 250
                              },
                              {
                                animation: 'additive',
                                delay: 200,
                                placeholder: '<span class="lightText">',
                                render_strategy: 'text-by-char',
                                items: "id\n"
                            },
                              {
                                animation: 'additive',
                                delay: 200,
                                placeholder: '<span class="lightText">',
                                render_strategy: 'text-one-shot',
                                items: "uid=0(root) gid=0(root) groups=0(root)\n"
                            },
                              {
                                animation: 'additive',
                                delay: 100,
                                placeholder: '<span class="lightText">',
                                render_strategy: 'text-one-shot',
                                items: "root@text.text ~ # "
                            },
                              {
                                animation: 'additive',
                                delay: 150,
                                placeholder: '<span class="lightText">',
                                render_strategy: 'text-by-char',
                                items: "./motd &\n"
                            },
                              {
                                animation: 'additive',
                                delay: 50,
                                placeholder: '<span class="lightText">',
                                render_strategy: 'text-one-shot',
                                items: "root@Text.text ~ # "
                            },
                         
                        ]
                    });
                      jQuery("#innerPreDiv").dynatexer('play', function() {showMOTD()});
                });

                  function showMOTD() {
                      if(!alreadyShown) {
                          alreadyShown = 1;
                        jQuery("#hideMeDiv").stop(true, true).fadeIn({ duration: 500, queue: false }).css('display', 'none').slideDown({ duration: 500, queue: false });
                          jQuery("#clickToSkip").hide();
                    }
                }
            </script>
         
          <div id="clickToSkip" style="position: absolute; bottom: 50px; right: 55px; text-align: right; font-size: 10px; color: rgb(144, 144, 144); display: none;">Click to skip</div>
        </div>
         
       
        <div id="hideMeDiv">

My dynatexer file looks like this :

  1. (function(a){function c(a,b){var c=b||typeof b==="undefined"?"<br />":"<br>";return(a+"").replace(/([^>\r\n]?)(\r\n|\n\r|\r|\n)/g,"$1"+c)}function d(b,c){if(!b.placeholder_tag){if(!b.placeholder||b.placeholder==""){b.placeholder_tag=target}else{placeholder_tag=a(b.placeholder);if(c.cursor&&c.cursor.placeholder_tag){b.placeholder_tag=placeholder_tag;b.placeholder_tag.insertBefore(c.cursor.placeholder_tag)}else{b.placeholder_tag=placeholder_tag;c.target.append(b.placeholder_tag)}}}}function e(a){if(!a.current_iterator){a.current_iterator=l[a.render_strategy](a.items)}}function f(a){this.current_char=0;this.text=a}function g(a){this.listed=false;this.text=a}function h(a){this.current_item=0;this.items=a}function i(a){var b=a.split(/\r\n|\r|\n/);this.delegate=new h(b)}function j(a,b,c,d){d.prepare();c=typeof c==="undefined"?function(){}:c;e(b);b.current_iterator.has_next()?animated=true:animated=false;var f=function(){if(a.running){if(b.current_iterator.has_next()){d.render();setTimeout(function(){if(a.running){f()}},b.delay)}else{c()}}};setTimeout(function(){f()},1);return animated}function m(b){a.each(b.content,function(a,b){b.current_iterator=null;b.placeholder_tag=null});b.current_content=0;if(b.cursor){b.target.children().not(b.cursor.placeholder_tag).remove()}else{b.target.children().remove()}}function n(a){if(a.cursor){a.cursor.current_iterator=null;if(a.cursor.placeholder_tag){a.cursor.placeholder_tag.children().remove();a.cursor.placeholder_tag.text("")}}}function o(c){c=a.extend({},a.fn[b].defaults.general,c);content=[];a.each(c.content,function(c,d){content.push(a.extend({},a.fn[b].defaults.content,d))});c.content=content;if(typeof c.cursor!="undefined"){c.cursor=a.extend({},a.fn[b].defaults.cursor,c.cursor)}return c}function p(a,c){c=o(c);var d=a.data(b);if(!d){a.data(b,{target:a})}d=a.data(b);d.loop=c.loop;d.content=c.content;d.current_content=0;d.times=0;d.running=false;d.cursor=c.cursor;if(typeof d.cursor!="undefined"){if(typeof d.cursor.placeholder=="undefined"||d.cursor.placeholder==""){d.cursor.placeholder="<span>"}d.cursor.times=0}}var b="dynatexer";f.prototype.has_next=function(){return this.current_char<this.text.length};f.prototype.next=function(){var a=this.text.charAt(this.current_char++);if(a=="\r"){a=content.text.charAt(this.current_item++);if(a=="\n"){a=content.text.charAt(this.current_item++)}a="<br />"}else if(a=="\n"){a="<br />"}return a};g.prototype.has_next=function(){return!this.listed};g.prototype.next=function(){this.listed=true;return c(this.text)};h.prototype.has_next=function(){return this.current_item<this.items.length};h.prototype.next=function(){return this.items[this.current_item++]};i.prototype.has_next=function(){return this.delegate.has_next()};i.prototype.next=function(){return(this.delegate.current_item!=0?"<br />":"")+this.delegate.next()};var k={additive:function(a,b,c){return j(a,b,c,{prepare:function(){d(b,a)},render:function(){b.placeholder_tag.html(b.placeholder_tag.html()+b.current_iterator.next())}})},replace:function(a,b,c){return j(a,b,c,{prepare:function(){if(!b.placeholder||b.placeholder=="")b.placeholder="<span>";d(b,a)},render:function(){b.placeholder_tag.html(b.current_iterator.next())}})}};var l={"text-by-char":function(a){return new f(a.toString())},"text-by-line":function(a){return new i(a.toString())},"text-one-shot":function(a){return new g(a.toString())},iterator:function(a){return a.iterator()},"array-items":function(a){return new h(a)}};var q={init:function(b){return this.each(function(){p(a(this),b)})},play:function(c){c=typeof c==="undefined"?function(){}:c;return this.each(function(){var d=a(this),e=d.data(b);if(e.running)return;e.running=true;var f=function(){if(e.running){if(e.current_content<e.content.length){content=e.content[e.current_content];k[content.animation](e,content,function(){++e.current_content;f()})}else{if(e.loop=="infinite"||e.loop<1){m(e);f()}else{++e.times;if(e.times<e.loop){m(e);f()}else{e.running=false;c()}}}}};f();var g=function(){if(e.running&&e.cursor){k[e.cursor.animation](e,e.cursor,function(){if(e.cursor.loop=="infinite"||e.cursor.loop<1){n(e);g()}else{++e.cursor.times;if(e.cursor.times<e.cursor.loop){n(e);g()}}})}};g()})},pause:function(){return this.each(function(){var c=a(this),d=c.data(b);d.running=false})},reset:function(){return this.each(function(){var c=a(this),d=c.data(b);d.running=false;d.times=0;if(typeof d.cursor!="undefined"){d.cursor.times=0}m(d);n(d)})},configure:function(c){return this.each(function(){var d=a(this),e=d.data(b);m(e);e.target.children().remove();p(d,c)})}};a.fn[b]=function(c){if(q[c]){return q[c].apply(this,Array.prototype.slice.call(arguments,1))}else if(typeof c==="object"||!c){return q.init.apply(this,arguments)}else{a.error("Method "+c+" does not exist on jQuery."+b)}};a.fn[b].defaults={general:{loop:1,content:[]},content:{animation:"additive",delay:0,placeholder:"<span>",render_strategy:"text-one-shot",items:""},cursor:{loop:"infinite",animation:"replace",delay:500,placeholder:"<span>",render_strategy:"array-items",items:[]}};a.fn[b].helper={counter:function(b){return{iterator:function(){var c={config:a.extend({start:1,end:100,step:1,mask:"%d"},b),has_next:function(){return this.index<=this.config.end},next:function(){var a=this.index;this.index+=Math.max(1,Math.min(this.config.step,Math.abs(this.config.end-this.index)));return this.config.mask.replace("%d",a)}};c.index=c.config.start;return c}}}}})(jQuery)

I cant remember having the data that was supposed to be written in, in my HTML physically, I am referring to the InnerPreDiv, but if I empty it like this, the output on my website stays static:


 
  1. <div id="Intro" onclick="showMOTD();">
         
              <pre><div id="innerPreDiv"><span class="lightText">guest@text.text:$ </span><span class="lightText">more random text<br></span><span class="lightText">WĘlcoϻe to myramdomsite </span><span class="lightText">AAAAAAAAAAAAAAAAA<br></span><span class="lightText">randomtext</span><span class="lightText">anotherrandomstring</span><span class="lightText">anotherrandomstring<br></span><span class="lightText">stringscarryon<br><br></span><span class="darkText"># somanystrings<br></span><span class="darkText">kernel died (signal 0, exit 11)<br></span><span class="darkText">Automatic reset in 3 seconds.</span><span class="darkText">....</span><span class="lightText"><br><br>root@text.text ~ # </span><span></span><span class="lightText">id<br></span><span class="lightText">uid=0(root) gid=0(root) groups=0(root)<br></span><span class="lightText">root@text.text ~ # </span><span class="lightText">./motd &amp;<br></span><span class="lightText">root@text.text ~ # </span></div></pre>
  2. #This part is where I call a file called dynatexer:
            <script type="text/javascript" src="/uploads_dynatexer.min.js"></script>
  3. #This part is where the text was written in initially - Changed the output a bit now
  4. #This is how it is in my HTML code.
            <script type="text/javascript">
             
                  var alreadyShown = 0;
             
                jQuery(document).ready(function() {
                    jQuery("#innerPreDiv").dynatexer({
                        loop: 1,
                        content: [
  5.                     ]
                    });
                      jQuery("#innerPreDiv").dynatexer('play', function() {showMOTD()});
                });

                  function showMOTD() {
                      if(!alreadyShown) {
                          alreadyShown = 1;
                        jQuery("#hideMeDiv").stop(true, true).fadeIn({ duration: 500, queue: false }).css('display', 'none').slideDown({ duration: 500, queue: false });
                          jQuery("#clickToSkip").hide();
                    }
                }
            </script>
         
          <div id="clickToSkip" style="position: absolute; bottom: 50px; right: 55px; text-align: right; font-size: 10px; color: rgb(144, 144, 144); display: none;">Click to skip</div>
        </div>
         
       
        <div id="hideMeDiv">

Does anyone know what I might be missing? I know it is something stupid and simple, but this was a project me and one of my mates did, unfortunately he cant's help me anymore, due to reasons that aren't of interest.


Cheers.