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

  • SEARCH
  • Home
  • 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 8567539
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T17:54:22+00:00 2026-06-11T17:54:22+00:00

I am trying to hide a footer when a form element is given focus.

  • 0

I am trying to hide a footer when a form element is given focus. I also want to show a footer when a form element loses focus, which the blur event should handle. I can’t get the focus or blur event to fire on a jQuery Mobile selectmenu form element.

Here is an example of one of my form elements –

<select id="radiology-study-provider" class="selectList"></select>

Here is the jQuery code that is supposed to hide my footer on focus and show it on blur (it is inside DOM ready) –

  $('.selectList').change(function(){
      console.log("the change event is firing");
  });
  $('.selectList').focus(function(){
      $('div:jqmData(role="footer")').hide(); // hide the footer
  });
  $('.selectList').blur(function(){
      $('div:jqmData(role="footer")').show(); // show the footer
  });

It is strange that the change event handler fires but focus and blur will not.

I have tried this below and it won’t work –

  $('.selectList').on('focus', function(){
      $('div:jqmData(role="footer")').hide(); // hide the footer
  });
  $('.selectList').on('blur', function(){
      $('div:jqmData(role="footer")').show(); // show the footer
  });

I also tried this –

   $('.selectList').bind( "focus", function(event, ui) {
       $('div:jqmData(role="footer")').hide(); // hide the footer
  });
   $('.selectList').bind( "blur", function(event, ui) {
       $('div:jqmData(role="footer")').hide(); // hide the footer
  });

I also tried the focusin() and focusout() events with no luck either. I tried dozens of selectors (div.ui-select was one of them). I don’t think it is an issue with the selector I am using.

I am using jQuery Mobile 1.1.0 and jQuery 1.7.1 – I have checked the jQuery Mobile selectmenu documentation at http://jquerymobile.com/test/docs/forms/selects/events.html, talked to the google, searched here, and can’t find this issue out.

  • 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-11T17:54:23+00:00Added an answer on June 11, 2026 at 5:54 pm

    This is what ended up working for me.

    document.addEventListener("deviceready", onDeviceReady, false);
    
    function onDeviceReady () {
        document.addEventListener("hidekeyboard", onKeyboardHide, false);
        document.addEventListener("showkeyboard", onKeyboardShow, false);
    
    }
    
    function onKeyboardHide() {
        $('div:jqmData(role="footer")').show(); // show the footer
    }
    
    function onKeyboardShow() {
        $('div:jqmData(role="footer")').hide(); // hide the footer
    }
    

    I came across this here on stack – Show hide keyboard is not working propery in android phonegap and noticed there are those 2 events you can listen for.

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

Sidebar

Related Questions

I am trying to hide/show a class of elements in a form depending on
Hi I am trying to hide a form element unless a particular dropdown value
i'm trying to hide/show some control on a page from Page_LoadComplete. If a put
I'm trying to hide elements with the same class name (float_form), but I'm also
I'm trying to hide window after its startup. I have own window-class which is
im trying to hide all the selected element on document ready, but only the
I'm trying to hide or show a div based on the value of some
I am trying to hide an element in my page (it is a YouTube
I'm trying to re-position a fixed footer in jQuery Mobile after I hide an
I'm trying to hide the number pad, but I do not want to implement

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.