Ryan Potter
Ryan Potter

Reputation: 835

jQuery Mobile custom select reverts to dialog.

I'm using the latest build of jQuery mobile 1.20 Final, and I have a custom select input that opens in a popup which is exactly like the ones here:

http://jquerymobile.com/demos/1.2.0/docs/forms/selects/custom.html

The issue I'm having is that when the height of the page is smaller than the popup, it opens a dialog instead of a popup. Is there a way of preventing this from happening?

Upvotes: 1

Views: 338

Answers (1)

Kaidul
Kaidul

Reputation: 15855

I don't know if there are any way to do that.But if it exists, it deals with the internal structure/code of JQM.I can give you a easy solution:

Suppose,the height of the select pop-up is 150px.Then modify your page CSS like that:

#pageId{
    height: auto;
    min-height: 160px; /* Some value greater than 150px, As I assume selectbox pop-up's height 150px*/   
}

Upvotes: 1

Related Questions