-
otherwhirlParticipant
Hello,
Is it possible to hide the ad banner i have in the header widget area of the desktop version of the theme in the mobile version?
In other words, I don’t want mobile users to experience the header ad.
Thanks
- This topic was modified 9 years, 11 months ago by otherwhirl.
Daniel TaraKeymasterYou can add this media query to your custom CSS:
@media (max-width: 736px) { #sidebar-header { display: none; } }
736px is the width of the viewport on iPhone 6 Plus in landscape mode which is currently the widest viewport on a smartphone. If you want to also hide it on tablets you can change it to 768px for portrait mode or 1024px for landscape mode.
otherwhirlParticipantActually now the banner on the desktop version is getting cut off for some reason.
It’s 736×98- This reply was modified 9 years, 11 months ago by otherwhirl.
- This reply was modified 9 years, 11 months ago by otherwhirl.
Daniel TaraKeymasterThis is not due to the code above, it doesn’t affect screens greater than 736px in any way, it’s most probably because of to another change.
otherwhirlParticipantHi,
so I have footer ads I need to disable for mobile as well.I tried the code you gave which worked in the header:
@media (max-width: 736px) {
#sidebar-header {
display: none;
}
}I tried using it with the following:
@media (max-width: 736px) {
#sidebar-footer {
display: none;
}
}I even tried this one:
@media (max-width: 736px) {
#footer {
display: none;
}
}otherwhirlParticipantI also would like to know how to disable javascript IM slider POP-up ad code?
Basically I want the ability to have control over all ads on the mobile template.
- This reply was modified 9 years, 10 months ago by otherwhirl.
You must be logged in to reply to this topic.