TTaylor Posted June 8, 2021 Share Posted June 8, 2021 Site URL: https://www.travelsandtreasures.com I've searched the forum and have been playing with this for hours. Any suggestions on how to center the content of a code block (it's on my home page). I've tried adding align="center" to the DIV tag adding class="center" to the IMG tag with .center { display: block; margin-left: auto; margin-right: auto; width: 50%;} Nothing works. I'm stumped. Link to comment
jsanzloz Posted June 8, 2021 Share Posted June 8, 2021 Hiya 👋 Try replacing those CSS lines with these ones: display:flex; justify-content: center; Link to comment
TTaylor Posted June 8, 2021 Author Share Posted June 8, 2021 55 minutes ago, jsanzloz said: Hiya 👋 Try replacing those CSS lines with these ones: display:flex; justify-content: center; Hi there, I tried both in the DIV tag, IMG tag, and SCRIPT tag ....didn't work and I'm not sure that I really know what I'm doing 🤪😂 Link to comment
tuanphan Posted June 10, 2021 Share Posted June 10, 2021 On 6/9/2021 at 1:50 AM, TTaylor said: Hi there, I tried both in the DIV tag, IMG tag, and SCRIPT tag ....didn't work and I'm not sure that I really know what I'm doing 🤪😂 Can you share link to page where you added Code Block? Wee don't see it on homepage Email me if you have need any help (free, of course.). Answer within 24 hours. Or send to forum message How to: Setup Password & Share url - Insert Custom CSS - Page Header - Upload Custom Font - Upload File - Find Block ID - Contact Customer Care Link to comment
kdear Posted May 5, 2022 Share Posted May 5, 2022 HI, I've been having a similar issue with code blocks in the footer. They don't center align. An example is here: https://www.insideaboldmind.com/blog/perfection-purpose The newsletter block is off-center. I also wanted the heading and category buttons to be center aligned but had problems with that too so have just made them left aligned for now. Any thoughts? Link to comment
creedon Posted May 6, 2022 Share Posted May 6, 2022 57 minutes ago, kdear said: I've been having a similar issue with code blocks in the footer. They don't center align. Your issue appears to be related to the summary block near the end of the page causing an overflow condition. I don't have an solution at this time but perhaps others do. 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
kdear Posted May 6, 2022 Share Posted May 6, 2022 18 minutes ago, creedon said: Your issue appears to be related to the summary block near the end of the page causing an overflow condition. I don't have an solution at this time but perhaps others do. Thank You! I'll reinsert the summary block and see if that helps otherwise I'll await others responses. Link to comment
kdear Posted May 6, 2022 Share Posted May 6, 2022 Thanks for the clue on that one. The issue was being caused by the summary block when the number of items exceeded the items per row by a large amount. I had the numbers of items set to the maximum 30 and then items per row set to 5. The issue is fixed when I set the number of items to 5 and items per row to 5. It not ideal, but it is good enough and now everything lines up nicely. THANKS!! creedon 1 Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment