Jump to content

Coding for different banners on homepage for desktop and mobile

Recommended Posts

  • Replies 1
  • Views 281
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

2 hours ago, vanbousfield said:

Site URL: https://quillfish-silver-hc63.squarespace.com/home

Hi there

I am wondering if I can add a different banner for my homepage as the current one works on desktop but the wording gets cut off on the mobile version?

I have added 2 banners one that suits each device - is there some CSS code to be able to hide the top one on mobile and hide the bottom one on desktop?

Thanks in advance

 

Please go to design>custom CSS and paste the following code

/* Hides the desktop banner on mobile*/
@media screen and (max-width: 764px) {
[data-section-id="625f8b6a1892c05f44a4988c"] {
   display:none !important;
}
}

/* Hides the  mobile banner on desktop*/
@media screen and (min-width: 765px) {
[data-section-id="6260be38da6738035da387a1"] {
   display:none !important;
}
}
Please let me know how it goes, and ask for help if it does not work. Please mark the answer as correct if it works. Thanks

Edited by TheSquareSpacer

Become a contributor to the largest resource for Squarespace and gain recognition from thousands of visitors.

Join us on this exciting journey. Ping us here!.

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

×
×
  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.