Support » Fixing WordPress » unknown script added via wp_head , how to find it ??

  • Hey guys ,
    In my wp site – in head section
    <script type="text/javascript"> if(!document.referrer || document.referrer == '') { document.write('<scr'+'ipt type="text/javascript" src=""></scr'+'ipt>'); } else { document.write('<scr'+'ipt type="text/javascript" src=""></scr'+'ipt>'); } </script>

    If you guys could notice minutely –
    url of jquery is incorrect instead of , further
    i dont want above script to be included.

    Now i am not sure from where this is being called
    I recehcked my functions.php files , and all the theme and external plugins file which i have installed , but i cant find from where this hook was fired.

    can some one suggest me way , i could find from where this script is being called ???

    Thanks in advance

Viewing 7 replies - 1 through 7 (of 7 total)
  • hey never mind – i found the hook from where is was being fired from , one of the plugin files.
    Please close this thread this issue is resolved.


    Where did you find it? i need to find also and can’t



    Forum Moderator

    Have you tried:

    – deactivating all plugins to see if this resolves the problem. If this works, re-activate the plugins one by one until you find the problematic plugin(s).

    – switching to the Twenty Eleven theme to rule out any theme-specific problems.

    resetting the plugins folder by FTP or PhpMyAdmin. Sometimes, an apparently inactive plugin can still cause problems.

    Hi esmi ,
    Thanks for the support.

    To locate from which file , it was being called.

    In windows search , I searched for all php files inside each plugin folder.

    Opened it up in notepad ++ , searched for script name , as appearing in wordpress head in all “open documents”. and i got the bug in ubermenu plugin was nulled version and had few lines of coded added up in between the main code.

    Hope it helps.


    Hi, i have the same issue. How to solve?

    Hi, I have the same issue. I already tried deactivating my plugins but the tag is still there. I tried changing my theme and it did load properly, but is there a way to go around this? I really cannot afford to change my layout, and I am not sure either if this is the main cause.



    Forum Moderator

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘unknown script added via wp_head , how to find it ??’ is closed to new replies.