Skip to Main Content

APEX

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

jQuery UI Dialog height:auto

InoLSep 8 2015 — edited Sep 8 2015

Hi

I am using Apex 5.0.1, Universal Theme. I am replacing the standard Alert and Confirm popups with jQuery Dialog. E.g. for Alert, I replaced the alert() with:

$.extend({ alert: function (message, title) {

  $("<div></div>").dialog( {

    open: function(event, ui) {

         $(".ui-dialog-titlebar-close").hide();

         $(".ui-dialog-content").css("padding","1em 1em");      

         },

    buttons: { "Ok": function () { $(this).dialog("close"); } },

    close: function (event, ui) { $(this).remove(); },

    resizable: false,

    title: title,

    modal: true,

    height: "auto"

  }).html(message);

}

});

This works nicely, except for one thing: height: "auto" is ignored. Apex generates a fixed height for the dialog content:

<div id="ui-id-3" class="ui-dialog-content ui-widget-content" style="display: block; width: auto; max-height: none; height: 69px; min-height: 45px;">

I  added

$(".ui-dialog-content").css("height","");

to the open function, but that was just ignored (running this line in Firebug did remove the height of 69px correctly).

Any suggestions how to force the "height: auto"?

See a demo here:

workspace: sqlint

user: OTN

pw: OTN123

page: 3

This post has been answered by timothyscottchambers-Oracle on Sep 8 2015
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Oct 6 2015
Added on Sep 8 2015
3 comments
1,372 views