Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

I just noticed there was this script in my source code:

<script src='/google_analytics_auto.js'></script>

I did not insert this script and I have no plugins, so I don't know why it's there? Does someone know how to remove that?

share|improve this question
5  
There is no such script in WordPress core. I don't think this can be answered in current form, you need to figure out where is it coming from in your site. –  Rarst Jul 4 '13 at 17:28
4  
It's probably part of your theme. –  vancoder Jul 4 '13 at 17:44
add comment

2 Answers

up vote 2 down vote accepted

The reason is you are using HostGator and enable the feature is Google Analytics Integration, by enable this one, HostGator will automatically add this snipped of code into your main website and all of it sub or add-on domain:

<script src='/google_analytics_auto.js'></script></head>

I my self also faced with this issue, my main website is http://nguyenhuutrong.com and I got the above line of code when viewing source, I tried to have one fresh Wordpress in my add-on domain, but it still be there. After I tried to install wordpress on my local (by using XAMPP) then I found out the root cause is Google Analytics Integration of HostGator.

You just going to cPanel, choose the Google Analytics Integration, at the configuration you just choose to uninstall the Google Analytics (UA) for your domain and it will work.

share|improve this answer
add comment

Check header.php and footer.php; sounds like that link is part of your theme and is pulling that script, possibly from a plugin that is supposed to be included with the theme or in the "must use" plugin folder, which is called mu-plugins in wp-content.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.