Morten77 Posted December 9, 2020 Share Posted December 9, 2020 Site URL: http://www.photosbyskovlund.com Hi Im quiet new with Squarespace, and hit some problems. One of them is when I in the storepage, want to use & in Black & White in the heading. The it shows up with a &, but it's not a problem in the main text. Is it possible to change this with a code? thanks in advance Morten Link to comment
creedon Posted December 10, 2020 Share Posted December 10, 2020 Please see the following. Let us know how it goes. Find my contributions useful? Please like, upvote, mark my answer as the best ( solution ), and see my profile. Thanks for your support! I am a Squarespace ( and other technological things ) consultant open for new projects. Link to comment
Morten77 Posted December 10, 2020 Author Share Posted December 10, 2020 Oh thanks mate. Sorry i don't find the other one, I have tried to search. Its works out well, after combining the two treads. Now im quiet close to run for now 🙌🏼 Link to comment
creedon Posted December 10, 2020 Share Posted December 10, 2020 7 minutes ago, Morten77 said: Sorry i don't find the other one, I have tried to search. Its works out well, after combining the two treads. No worries. I updated my code including the product grid and the breadcrumbs in the selector. That way you don't have to duplicate two virtually identical versions of the code in Page Header Code Injection. Find my contributions useful? Please like, upvote, mark my answer as the best ( solution ), and see my profile. Thanks for your support! I am a Squarespace ( and other technological things ) consultant open for new projects. Link to comment
Morten77 Posted December 10, 2020 Author Share Posted December 10, 2020 Oh i don't know what happened - it dont work now. Link to comment
Morten77 Posted December 10, 2020 Author Share Posted December 10, 2020 Now it work again 🙌🏼 Link to comment
ChrisKing Posted December 15, 2020 Share Posted December 15, 2020 On 12/9/2020 at 11:50 PM, creedon said: Add the following to Store Settings > Advanced > Page Header Code Injection. <script> $( ( ) => { $( '.grid-title, .ProductItem-nav-breadcrumb-link' ).each ( function ( ) { $this = $( this ) let html = $this.html ( ).replace ( /&amp;+/g, '&' ); $this.html ( html ); } ); } ); </script> This is very similar to an issue within another thread. Let us know how it goes. Following this thread. Having trouble removing this problem from our merch store: https://www.chriskingandthegutterballs.com/merch Link to comment
ChrisKing Posted December 15, 2020 Share Posted December 15, 2020 Just now, ChrisKing said: Following this thread. Having trouble removing this problem from our merch store: https://www.chriskingandthegutterballs.com/merch Tried the code. No luck unfortunately. Link to comment
creedon Posted December 15, 2020 Share Posted December 15, 2020 54 minutes ago, ChrisKing said: Following this thread. Having trouble removing this problem from our merch store I'd be happy to try and extend my code to cover your use case but I'm not seeing any funky ampersands. Could you point me to a more specific page where the problem is occurring? Or did you replace your & with 'N'? If the later if you could have just one product with the & in it then I'd have something to work with. Find my contributions useful? Please like, upvote, mark my answer as the best ( solution ), and see my profile. Thanks for your support! I am a Squarespace ( and other technological things ) consultant open for new projects. Link to comment
Morten77 Posted January 4, 2021 Author Share Posted January 4, 2021 Hi @creedon You help me a lot with the & problem, and it was working. But now its appear again, but only on the shop frontpage, not under the product page. Hmmm - what to do? https://www.photosbyskovlund.com/shop Link to comment
creedon Posted January 5, 2021 Share Posted January 5, 2021 @Morten77 I have updated the code in my previous code post. Find my contributions useful? Please like, upvote, mark my answer as the best ( solution ), and see my profile. Thanks for your support! I am a Squarespace ( and other technological things ) consultant open for new projects. Link to comment
Morten77 Posted January 5, 2021 Author Share Posted January 5, 2021 1 hour ago, creedon said: @Morten77 I have updated the code in my previous code post. I have used this one: <script> $( ( ) => { $( '.grid-title, .ProductItem-nav-breadcrumb-link' ).each ( function ( ) { $this = $( this ) let html = $this.html ( ).replace ( /&amp;+/g, '&' ); $this.html ( html ); } ); } ); </script> Link to comment
creedon Posted January 6, 2021 Share Posted January 6, 2021 23 hours ago, Morten77 said: I have used this one: Replace that code with the code I updated in my Dec. 9th post. Find my contributions useful? Please like, upvote, mark my answer as the best ( solution ), and see my profile. Thanks for your support! I am a Squarespace ( and other technological things ) consultant open for new projects. Link to comment
Morten77 Posted January 11, 2021 Author Share Posted January 11, 2021 On 1/6/2021 at 8:31 AM, creedon said: Replace that code with the code I updated in my Dec. 9th post. Hmm, I can't find a post in here form Dec. 9th 🤔 Link to comment
creedon Posted January 11, 2021 Share Posted January 11, 2021 It's right here... Find my contributions useful? Please like, upvote, mark my answer as the best ( solution ), and see my profile. Thanks for your support! I am a Squarespace ( and other technological things ) consultant open for new projects. Link to comment
Morten77 Posted January 11, 2021 Author Share Posted January 11, 2021 4 hours ago, creedon said: It's right here... It was the one i used but its stille appear on the shop frontpage Link to comment
creedon Posted January 12, 2021 Share Posted January 12, 2021 Move the following... from Settings > Advanced > Code Injection > FOOTER to Settings > Advanced > Code Injection > HEADER Don't replace the code in the HEADER, if any, just add to it. <script src="https://code.jquery.com/jquery-3.4.1.js"></script> The jQuery needs to load before any code that needs it does. While I was diagnosing the issue I noticed shinyApp is spewing a continues stream of console.log messages. It makes tracking any issues very difficult and may have other undesired effects. I don't have a solution but it wouldn't hurt to contact the developer to ask what is going on. Find my contributions useful? Please like, upvote, mark my answer as the best ( solution ), and see my profile. Thanks for your support! I am a Squarespace ( and other technological things ) consultant open for new projects. Link to comment
Recommended Posts
Archived
This topic is now archived and is closed to further replies.