alternadiv
Well-known member
I have a few sidebar widgets, but I want just one of them to appear at the very top of the page on the mobile layout. Can that be done?
Yeah, but I want it on the side on the desktop view and at the top on mobile view.Hello,
Wich widget you want to place at the very top of the page ?
In Admin Panel, Widget section, you can choose a widget and make it appear at different places of the forum. Choose "at the top of the main view" or "below/beyond the top breadcrumbs".
You can try different locations to see which one is right for you.
.p-body-pageContent [data-widget-definition="member_stat"]
{
display: none;
}
@media (max-width: @xf-responsiveWide)
{
.p-body-pageContent [data-widget-definition="member_stat"] { display: block; }
.p-body-sidebar [data-widget-definition="member_stat"] { display: none; }
}
Thank you!@Tacoma3G a somewhat easy solution would be to just create the widget twice and hide via CSS.
Code:.p-body-pageContent [data-widget-definition="member_stat"] { display: none; } @media (max-width: @xf-responsiveWide) { .p-body-pageContent [data-widget-definition="member_stat"] { display: block; } .p-body-sidebar [data-widget-definition="member_stat"] { display: none; } }
Top line would hide the one inside the content area, then show in mobile while hiding the other one in mobile.
We use essential cookies to make this site work, and optional cookies to enhance your experience.