How Do I Show or Hide HTML Widgets for Ads on Mobile or Desktop in SoCast Engage?

How Do I Show or Hide HTML Widgets for Ads on Mobile or Desktop in SoCast Engage?

Yes, you can control the visibility of HTML widgets for ads on mobile or desktop in SoCast Engage by using built-in CSS classes. This allows you to display one widget on desktop and another on mobile, hiding each on the opposite platform.

To show or hide HTML widgets based on screen size:

  1. When editing your page in SoCast Engage, add your HTML widgets as needed for desktop and mobile ad units.
  2. For the widget you want to hide on small screens (mobile), add the class .sc-hide-on-small-screens to the widget's HTML container.
  3. For the widget you want to show only on small screens (mobile), add the class .sc-show-on-small-screens to the widget's HTML container.
  4. The breakpoint for these classes is 960px. Content with .sc-hide-on-small-screens will be hidden on screens narrower than 960px, and content with .sc-show-on-small-screens will be shown only on screens narrower than 960px.

This method allows you to manage ad visibility responsively without custom code. If you need further assistance implementing these classes, please contact SoCast support.