MaverivckMPP Posted April 28, 2020 Share Posted April 28, 2020 Site URL: https://maverickmpp.com/home-copy I have two gallerys, one for mobile and one for desktop/tablet. I can't seem only hide one at a time though. Can I use the data-Id to do this? https://www.maverickmpp.com/home-copy Link to comment
tuanphan Posted April 28, 2020 Share Posted April 28, 2020 Yes. You can use [data-section-id="abcxyz123tuanphan"] {display:none;} Which gallery for desktop, which for mobile? 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
MaverivckMPP Posted April 28, 2020 Author Share Posted April 28, 2020 Figuered this out last night, used this exact line! Used the data sections to hide one on mobile and one on desktop. Works perfect if you want a different mobile slide show and a desktop. Code is below if anyone needs the same help. //Hide desktop slide show on mobile// @media only screen and (max-width: 640px) { [data-section-id="sectionIDhere"] { display: none; } } //Hide mobile slide show on desktop// @media only screen and (min-width: 641px) { [data-section-id="sectionIDhere"] { display: none; } } Link to comment
tuanphan Posted April 29, 2020 Share Posted April 29, 2020 15 hours ago, MaverivckMPP said: Figuered this out last night, used this exact line! Used the data sections to hide one on mobile and one on desktop. Works perfect if you want a different mobile slide show and a desktop. Code is below if anyone needs the same help. //Hide desktop slide show on mobile// @media only screen and (max-width: 640px) { [data-section-id="sectionIDhere"] { display: none; } } //Hide mobile slide show on desktop// @media only screen and (min-width: 641px) { [data-section-id="sectionIDhere"] { display: none; } } SS 7.1 use max-width:767px and min-width:768px 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
e_robertson Posted July 8, 2020 Share Posted July 8, 2020 I'm keen to do something similar on this website: www.felicitymara.co.uk How do I find the data-section-id for the gallery? Link to comment
tuanphan Posted July 8, 2020 Share Posted July 8, 2020 6 hours ago, e_robertson said: I'm keen to do something similar on this website: www.felicitymara.co.uk How do I find the data-section-id for the gallery? https://chrome.google.com/webstore/detail/squarespace-id-finder/igjamfnifnkmecjidfbdipieoaeghcff?hl=en 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
e_robertson Posted July 9, 2020 Share Posted July 9, 2020 @tuanphan Thank you. Do you know why this isn't working for me? /*Hide desktop slide show on mobile*/ @media only screen and (max-width: 767px) { [data-section-id="#block-yui_3_17_2_1_1594283337848_3771"] { display: none !important; } } /*Hide mobile slide show on desktop*/ @media only screen and (min-width: 768px) { [data-section-id="#block-yui_3_17_2_1_1594283751431_4609"] { display: none !important; } The website is www.felicitymara.co.uk and the password is felicity123 Link to comment
e_robertson Posted July 9, 2020 Share Posted July 9, 2020 I figured this one out. The code now reads: /*Hide desktop slide show on mobile*/ @media only screen and (max-width: 767px) { #block-yui_3_17_2_1_1594283337848_3771 { display: none !important; } } /*Hide mobile slide show on desktop*/ @media only screen and (min-width: 768px) { #block-yui_3_17_2_1_1594283751431_4609 { display: none !important; } } Link to comment
Recommended Posts
Archived
This topic is now archived and is closed to further replies.