• Skip to main content
  • Skip to forum navigation

StudioPress

  • Shop for Themes
  • My StudioPress

Forum navigation

  • Home
  • General Genesis Discussions
  • StudioPress Themes
  • Genesis Blocks
    • Genesis Blocks
    • Genesis Custom Blocks
  • Retired Themes
  • FAQs
  • Forum Rules
  • Internationalization and Translations
  • Forum Bugs and Suggestions
  • Forum Log In

Are You Using The WordPress Block Editor?

Genesis now offers plugins that help you build better sites faster with the WordPress block editor (Gutenberg). Try the feature-rich free versions of each plugin for yourself!

Genesis Blocks Genesis Custom Blocks

Adding a footer script

Welcome!

These forums are for general discussion on WordPress and Genesis. Official support for StudioPress themes is offered exclusively at My StudioPress. Responses in this forum are not guaranteed. Please note that this forum will require a new username, separate from the one used for My.StudioPress.

Log In
Register Lost Password

Community Forums › Forums › Archived Forums › General Discussion › Adding a footer script

This topic is: not resolved

Tagged: #footer script #addingcodejustbeforeclosingbodytagbodytag

  • This topic has 9 replies, 2 voices, and was last updated 8 years, 1 month ago by Victor Font.
Viewing 10 posts - 1 through 10 (of 10 total)
  • Author
    Posts
  • September 16, 2017 at 11:50 pm #211576
    Renu Bakshi
    Member

    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 #211577
    Victor Font
    Moderator

    You did what you were supposed to do. Please post a link to the site.


    Regards,

    Victor
    https://victorfont.com/
    Call us toll free: 844-VIC-FONT (842-3668)
    Have you requested your free website audit yet?

    September 17, 2017 at 7:42 am #211582
    Renu Bakshi
    Member
    This reply has been marked as private.
    September 17, 2017 at 8:11 am #211584
    Victor Font
    Moderator

    You may possibly have a plugin conflict. You have a couple of scripts that have been almost completely replaced with this: \\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\"


    Regards,

    Victor
    https://victorfont.com/
    Call us toll free: 844-VIC-FONT (842-3668)
    Have you requested your free website audit yet?

    September 17, 2017 at 8:52 am #211587
    Renu Bakshi
    Member

    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
    Victor Font
    Moderator

    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.


    Regards,

    Victor
    https://victorfont.com/
    Call us toll free: 844-VIC-FONT (842-3668)
    Have you requested your free website audit yet?

    September 17, 2017 at 9:41 am #211592
    Renu Bakshi
    Member

    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 Bakshi

    September 18, 2017 at 5:32 am #211609
    Victor Font
    Moderator

    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.


    Regards,

    Victor
    https://victorfont.com/
    Call us toll free: 844-VIC-FONT (842-3668)
    Have you requested your free website audit yet?

    September 18, 2017 at 5:48 am #211610
    Renu Bakshi
    Member

    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
    Victor Font
    Moderator

    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.


    Regards,

    Victor
    https://victorfont.com/
    Call us toll free: 844-VIC-FONT (842-3668)
    Have you requested your free website audit yet?

  • Author
    Posts
Viewing 10 posts - 1 through 10 (of 10 total)
  • The forum ‘General Discussion’ is closed to new topics and replies.

CTA

Ready to get started? Create a site or shop for themes.

Create a site with WP EngineShop for Themes

Footer

StudioPress

© 2025 WPEngine, Inc.

Products
  • Create a Site with WP Engine
  • Shop for Themes
  • Theme Features
  • Get Started
  • Showcase
Company
  • Brand Assets
  • Terms of Service
  • Accptable Usse Policy
  • Privacy Policy
  • Refund Policy
  • Contact Us
Community
  • Find Developers
  • Forums
  • Facebook Group
  • #GenesisWP
  • Showcase
Resources
  • StudioPress Blog
  • Help & Documentation
  • FAQs
  • Code Snippets
  • Affiliates
Connect
  • StudioPress Live
  • StudioPress FM
  • Facebook
  • Twitter
  • Dribbble