- This topic has 18 replies, 4 contibutors, and was last updated 9 years, 10 months ago by .
-
Question
Answers
- The question ‘Mobile Header’ is closed to new replies.
BuddyBoss Home – Web › Support Forums › Themes › Boss. theme › Mobile Header
Tagged: breakpoints, mobile header
What do I need to add to invoke the mobile header on iPad? Normal desktop to be shown on laptop screens and above?
Thanks,
Paul.
@tjchester Thanks 🙂 I can see the theme detects for mobile just can’t figure out how to change that.
@style960 we are using CSS media inquiries…I’m not sure if there is any PHP that does the same we can utilize.
@tjchester Just CSS? I’ve tried adding the mobile header styling to tablets+ but iPad retained the normal header.
@style960 problem is that iPads have a screen resolution that rivals desktops. I do not believe you can use media queries to filter tablets. I have a request with the devs to determine if we can do this via PHP.
@tjchester My issue is that while I do want to use Boss I find the BuddyPanel eats up to much real estate on and iPad or similar size tablet screen. I am aware that I can set that to be collapsed by default, but then you’re effectively hiding your primary navigation, which isn’t good practice. An alternative would be to use the Titlebar menu as primary, but the limitations of iPads in portrait mode mean there’s a good chance part of that menu is going to collapse forcing the user to expand it themselves. In my opinion, the only intuitive solution is to use the slide panels. Hope the devs can provide a workaround.
@style960 would it be satisfactory to have a setting to default the menu closed only on ipads?
Set the menu state to default closed then try this code: (I don’t have an ipad so I can’t test)
$isiPad = (bool) strpos($_SERVER['HTTP_USER_AGENT'],'iPad');
if(!$isipad){
add_filter( 'body_class','buddyboss_no_buddypanel' );
function buddyboss_no_buddypanel( $classes ) {
//show buddypanel if NOT ipad
$classes[] = 'left-menu-open';
return array_unique( $classes );
}
}
@tjchester I’d prefer not purely because the user is then left to guess what each icon links to, for a short time at least until they’re used to navigating the site. Thanks.
@tjchester Any response to this TJ? I’m mindful I still have more testing to do while I am in the refund window. Thanks.
@style960 this is something we can do but there is no quick fix unfortunately.
@tjchester Ok thanks. I appreciate the response although it’s not particularly clear for me. I’ll be putting a refund request in if there’s no estimated timeline. Thanks again.
@style960 If you can wait a bit, we’re working on an update for this. I think we can be done before the end of this month.
We’ll be changing the structure of our CSS, so there is a single stylesheet for desktop, mobile, and “global” (one for each). We will use device detection to determine if we should serve mobile or desktop. And then in admin, you can select if you want to show mobile or desktop layouts to : Desktop, Tablets, Phones. And we’ll fallback to media queries where device detection fails.
@michael Sounds robust, I’ll hang on for that.
Cool, thanks. If you want to test it pre-release, let me know.