JanetPassionfolk Posted June 14 Posted June 14 Hi I am trying to turn my gallery on home page into 1 image per line on mobile (it is 2 on desktop). I have copied in this code sourced from this forum but I keep getting a syntax error. What I am I doing wrong? Thanks! <style> @media screen and (max-width:767px) { .gallery-masonry-wrapper.gallery-masonry-list--ready { height: auto !important; } figure.gallery-masonry-item { position: relative !important; width: 100% !important; transform: unset !important; } .gallery-masonry-item-wrapper { height: auto !important; } .gallery-masonry .gallery-masonry-item[data-loaded] img { width: 100% !important; } .gallery-masonry { padding-left: 0 !important; padding-right: 0 !important; } } </style>
Lesum Posted June 14 Posted June 14 @JanetPassionfolk Hi! Remove <style> from line 36 and </style> from line 57 in your code. If my comments were useful, please like or mark my solution as answer so others can scroll to it quickly. Sam Web Developer & Digital Designer ☕ Did you find my contribution helpful? Buy me a coffee?
JanetPassionfolk Posted June 16 Author Posted June 16 thanks so much for your reply. It didnt seem to work but I will try again tomorrow!
Solution tuanphan Posted June 17 Solution Posted June 17 You need to paste your code to Homepage Header Code Injection. To access Header Injection > Hover on Homepage (on Main Navigation or Not Linked) > You will see a gear icon > Click on it > Advanced > Look right box. JanetPassionfolk 1 Email me if you have need any help (free, of course.). Answer within 24 hours. Or send to forum message Contact Customer Care - Learn CSS - Buy me a coffee (thank you!)
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment