Support » Fixing WordPress » TinyMCE script, WP not working anymore

  • Resolved Unduro

    (@unduro)


    Hello everyone, i wanted to add js to TinyMCE in WP-admin so i put this in my functions.php

    $in['setup'] = <<<JS
    [function(ed) {
               ed.onPreInit.add(function(ed) {
               console.debug('PreInit: ' + ed.id);
               console.debug(ed.initialized);
               var ec = ed.getDoc();
               var head = ec.getElementsByTagName("head")[0];
               var script = ec.createElement("script");
               script.src = "http://ajax.googleapis.com/ajax/libs/jquery/1.8.0/jquery.min.js";
              //script.text  = "alert('voila!');"
               script.setAttribute('type','text/javascript');
               head.appendChild(script);
          });
     }
    ][0]
    JS;

    It’s F**** up my site, nothing works anymore, i have removed it ofcourse, but the error is still there.
    “NetworkError: 500 Internal Server Error – “

    Dose anyone have an ideea on how to fix this without reinstalling WP?

    Thanks

  • The topic ‘TinyMCE script, WP not working anymore’ is closed to new replies.