Get rid of HTML text above announcement bar in Shopify store

Get rid of HTML text above announcement bar in Shopify store

maliagibson
Visitor
3 0 0

Hi, how do I get rid of this HTML code above my announcement bar of magicisla.com? I've tried everything but can't figure it out. I also have a few friends that have Shopify stores and the text appears above their announcement bars as well.

 

maliagibson_1-1702402212218.png

 

 

Here's the full HTML code in text format:

 

"); } else { win._boomrl = function() { bootstrap(); }; if (win.addEventListener) { win.addEventListener("load", win._boomrl, false); } else if (win.attachEvent) { win.attachEvent("onload", win._boomrl); } } doc.close(); } var link = document.createElement("link"); if (link.relList && typeof link.relList.supports === "function" && link.relList.supports("preload") && ("as" in link)) { window.BOOMR.snippetMethod = "p"; link.href = window.BOOMR.url; link.rel = "preload"; link.as = "script"; link.addEventListener("load", promote); link.addEventListener("error", function() { iframeLoader(true); }); setTimeout(function() { if (!promoted) { iframeLoader(true); } }, LOADER_TIMEOUT); BOOMR_lstart = new Date().getTime(); parentNode.appendChild(link); } else { iframeLoader(false); } function boomerangSaveLoadTime(e) { window.BOOMR_onload = (e && e.timeStamp) || new Date().getTime(); } if (window.addEventListener) { window.addEventListener("load", boomerangSaveLoadTime, false); } else if (window.attachEvent) { window.attachEvent("onload", boomerangSaveLoadTime); } if (document.addEventListener) { document.addEventListener("onBoomerangLoaded", function(e) { e.detail.BOOMR.init({ ResourceTiming: { enabled: true, trackedResourceTypes: ["script", "img", "css"] }, }); e.detail.BOOMR.t_end = new Date().getTime(); }); } else if (document.attachEvent) { document.attachEvent("onpropertychange", function(e) { if (!e) e=event; if (e.propertyName === "onBoomerangLoaded") { e.detail.BOOMR.init({ ResourceTiming: { enabled: true, trackedResourceTypes: ["script", "img", "css"] }, }); e.detail.BOOMR.t_end = new Date().getTime(); } }); } })();

 

Replies 13 (13)

StephensWorld
Shopify Partner
1398 173 362

That looks like coding you probably added to your theme in the wrong place -- or else you tried editing the theme's coding and broke it. You'd need to revert your coding changes, or else install a fresh version of the theme (and set it up again). 

 

If the coding still shows on a fresh version of the theme, then it's being generated from an app you're using. In that case, you'd need to contact the support team that runs the app, or else remove the app. 

★ Did my post help? If yes, then please like and accept solution. ★

https://stephens.world
support@stephensworld.ca

maliagibson
Visitor
3 0 0

Hi there! I actually didn't mess with the code. Do you know which app might be causing this?

maliagibson
Visitor
3 0 0

Also, I've seen this on over 20 shopify stores today. Here's an example: https://smileycookie.com

PaulNewton
Shopify Partner
6722 610 1433

You failed to provide a storefront password always keep other people in mind need to be able to access a thing to analyze a thing.

 

Go contact a shopify advisor directly help.shopify.com

 

That looks like shopify boomerang javascript rendered by content_for_header is in turn being treated as text. Either because the theme has bad html, the boomerang js has some error, or another app immediatly before it in content_for_header's output has some error.

 

 

Also try validating the theme https://validator.w3.org/ , or a theme rollback to check for better behaving code.

Save time & money ,Ask Questions The Smart Way


Confused? Busy? Get the solution you need paull.newton+shopifyforum@gmail.com


Problem Solved? ✔Accept and Like solutions to help future merchants

Answers powered by coffee Buy Paul a Coffee for more answers or donate to eff.org


StephensWorld
Shopify Partner
1398 173 362

I just checked out that site and I'm not seeing a bunch of code at the top. 

 

smiley cookie.png

 

I wouldn't be able to guess at which app is causing the issue without seeing the live version of your store (would need a URL, and storefront password if you have one set). 

 

However, I still think this is a coding issue within your theme, rather than an app issue -- just based on the placement of it from within your screenshot. 

 

I'd try adding a fresh version of the theme (or a different theme entirely) and seeing if the issue still shows/happens.

★ Did my post help? If yes, then please like and accept solution. ★

https://stephens.world
support@stephensworld.ca

johnny5678
Tourist
11 1 0

Screenshot 2024-04-28 170929.png

johnny5678
Tourist
11 1 0

I have the same issue to it is on every theme i open and it is also in the previews when you view a theme

Elias
Shopify Staff
3076 300 535

Hey, @johnny5678.

 

Thank you for joining the thread.

 

If there are codes showing in the preview or on the storefront, then it's usually due to custom coding that wasn't added correctly - such as missing an opening or closing bracket. To resolve this, we'd recommend reviewing the coding that you've added for the announcement bar. You can also try rolling back to an earlier version of your theme or install a fresh copy of the Dawn theme and then try adding the snippet of codes to the theme again.

 

If you have any other questions on this topic, then don't hesitate to let us know.

Elias | Social Care @ Shopify 
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Mark it as an Accepted Solution
 - To learn more visit the Shopify Help Center or the Shopify Blog

johnny5678
Tourist
11 1 0

i did look but idk what to look for bc i didnt edit code this was the first time i even went in here

 

johnny5678
Tourist
11 1 0

ok so i figured out some code was missing these <> but i still have tiny bit of error code left and i cant figure it out 

rel="stylesheet" href="//flashpointbeauty.org/cdn/shop/t/9/assets/component-predictive-search.css?v=118923337488134913561714337815" media="print" onload="this.media='all'" > class="gradient">

 
taahirahs
Visitor
1 0 0

I'm having the exact same problem. My website was completely fine but returned a few days later to this code on top. Please fix Shopify.

PageFly-Richard
Shopify Partner
4564 1046 1707

Hi @maliagibson 

 

This is Richard from PageFly - Shopify Page Builder App

 

Please check your theme code syntax in the theme.liquid to make sure those code are placed in the correct script tag.

 

If you are not sure about what changes caused that, you can also revert the history of the theme code too.

 

And you can try to disable some app in Shopify Cutomize > app extension.

 

 

Hope this can help you solve the issue 

 

Best regards,

Richard | PageFly

Please let me know if it works by giving it a Like or marking it as a solution!


➜ Optimize your Shopify store with PageFly Page Builder (Free plan available) 


All features are available from Free plan. Live Chat Support is available 24/7.

GameRoomGalore
New Member
4 0 0

Hello Richard! My name is Cannon and I have this exact same issue on my store with the exact same body of text appearing at the top of my website, along with all the other community comments I have been studying trying, I have not succeeded in getting rid or hiding this large body of text!

 

I have searched and combed through each individual page of layout, sections, snippets, etc. and have not found that body of code anywhere within the pages hoping that it was not encased in script tags. I have tried both enabling and disabling Javascript extensions for the browser and any other extensions-as well as trying to open the site in an incognito browser. 

Additionally I have tried opening other themes and redownloading the Debutify theme that I am using and the code is still appearing at the top.

 

I have not made any changes to the theme code at all and the only website design I have done is just on the website customization tools as the main builder.

 

Any advice would be great! The website is    gameroomgalore.com    and the password is    "GRG84862"

 

Best,

Cannon