Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8016683
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 4, 20262026-06-04T20:36:31+00:00 2026-06-04T20:36:31+00:00

im currently working on a website for mobile devices and im using jquery mobile.

  • 0

im currently working on a website for mobile devices and im using jquery mobile.

I have my header in a fixed position by using:

<header data-role="header" data-position="fixed">

This works perfectly fine, however when the page is viewed on a device in landscape mode, the header takes up alot of the space.

Is it possible with jquery mobile to set data-position=”fixed” only in portrait mode and have a NOT fixed header in landscape mode?

Thanks in advance!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-04T20:36:34+00:00Added an answer on June 4, 2026 at 8:36 pm

    You could bind to the orientationchange event and call $("[data-position='fixed']").fixedtoolbar('hide'); on the header.

    This is the jQuery Mobile page that talks about the methods available on the fixed tool bars http://jquerymobile.com/demos/1.1.0/docs/toolbars/bars-fixed-methods.html.

    And these are the available events http://jquerymobile.com/demos/1.1.0/docs/api/events.html, one of which is orientationchange.

    You can try using the actual selector shown with the data-position attribute rather than the #header. It might take a little bit of debugging to get it to work but no reason why it should not.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Im currently working on a mobile version of a website, everything is great, works
I am currently working on a website and lately have been using GD with
I'm using jQuery Mobile on an MVC 3 website. Working well except that I
I'm currently working on this website and have just noticed a problem with the
I am currently working on a website that will have a high volume of
I'm currently working on this website (http://www.jowannes.com/thomasschoof/flash/LauraBarsby.html) and I created a little gallery. When
I am currently working on a website which includes using Datatables. After customizing a
I am currently working on a registration based website, and I have the server
I am currently working on a mobile website and I could use some help
I'm working on a mobile friendly website & I'm a bit baffled by this

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.