September 16, 2017 at 11:50 pm #211576
I am using Genesis frame work and Modern Blogger Pro child theme. I want to add a jawascript just before the closing body tag. To do this I opened wordpress dashboard and clicked on gensis in the left side bar, clicked on Theme settings,put the jawascipt in the Footer Scripts box and clicked on saving. Cleared the browser's cache. But the jawascript code is not appearing in the document source.
Here is the jawascript: <script src="//z-na.amazon-adsystem.com/widgets/onejs?MarketPlace=US&adInstanceId=c85c8855-aaf0-4059-b6eb-f49ba9614543"></script>
Please help.September 17, 2017 at 5:54 am #211577September 17, 2017 at 7:42 am #211582This reply has been marked as private.September 17, 2017 at 8:11 am #211584
You may possibly have a plugin conflict. You have a couple of scripts that have been almost completely replaced with this: \\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\"
September 17, 2017 at 8:52 am #211587
I need your help on two issues:
(i) Yes, I also saw this in the source code. I first used footer widget to place the jawascript immediately before end of the body, which I later came to know that a footer widget can be used for placing html code and not jawascript. I want to remove this now: </div></footer></div><script src="//z-na.amazon-adsystem.com/widgets/onejs?MarketPlace=US&adInstanceId=c85c8855-aaf0-4059-b6eb-f49ba9614543"></script> As this code is incorrect because I used footer widget for adding jawascript which is not the correct way. And I don't know how to remove this. Please advise how can I remove this code now?
(ii) As far as plugins are concerned, I am using latest versions of 4 reputed plugins only. (i) AdSense Integration WP QUADS (ii) Akismet Anti-Spam (iii) WP Smush (iv) Yoast SEO Premium. So, may be the problem is not due to plugins.September 17, 2017 at 9:29 am #211591
The amazon script is not on your site. I don't know what you mean with question 1.
Plugins, regardless of how reputable, can still cause problems. First try replacing the bad code with good code. If the bad code is still in your source, turn off all plugins. Does the problem go away? If so, turn them on again one at a time and see if the problem returns.
September 17, 2017 at 9:41 am #211592
I will turn of the plugins as suggested by you. But I don't know method to remove bad code. Can you please tell me how I can remove a code or bad part of a code?
Regards...... Renu BakshiSeptember 18, 2017 at 5:32 am #211609
I can't tell you where the bad code is. It is not displaying on your site. You say it's in a footer widget, then delete the widget. It does not appear to be in your widgets though otherwise I would see it in your source code. If it's added through a WordPress hook in functions.php, then delete the code in that file. I can't help you further with this issue. The amazon code is not on your site. As far as I can tell, you have nothing to delete.
September 18, 2017 at 5:48 am #211610
Victor, Thank you so much for all your help and patience. I am not very familiar with coding and editing body section of my wordpress site. So, asking so many basic questions.
This is the code I am talking about: </div></footer></div><script src="//z-na.amazon-adsystem.com/widgets/onejs?MarketPlace=US&adInstanceId=c85c8855-aaf0-4059-b6eb-f49ba9614543"></script>
It's appearing in the source code. As far as I remember, I added this jawascript using footer widget. I came to know later footer widget can not add jawascript. I have already deleted this code from the footer widget, but it's still appearing in the source code. I want to remove it from the source code, but don't know how I can do it?
Thanks once again for all your help.September 18, 2017 at 3:34 pm #211616
I see the code now. It is not in the footer widget area or even in the footer. It is in the after footer area. How it got there, I have no idea with out examining the admin area of your site. I can't do that though as a community volunteer. All I can suggest is look for code in functions.php, if you are using Genesis Simple Hooks, look in there, or see if you have a widget in the after footer area.
- The forum ‘General Discussion’ is closed to new topics and replies.