Opened 3 years ago

Closed 3 years ago

Last modified 3 years ago

#8484 closed bug (fixed)

Text of buttons in dialog is not shown with jquery 1.8.0

Reported by: matzes Owned by:
Priority: minor Milestone: 1.8.23
Component: ui.dialog Version: 1.8.22
Keywords: Cc:
Blocked by: Blocking:

Description

The text of buttons in dialog will not appear when used with jquery 1.8.0. Only an empty button is shown. http://jsbin.com/esokix/3

Works as expected with jquery 1.7.2 http://jsbin.com/esokix/2

$("#dlg").dialog({
  buttons: [
    {
      text: "close"
    }
  ]
});

Change History (11)

comment:1 Changed 3 years ago by marianoguerra

same as the one I reported some seconds after :)

http://bugs.jqueryui.com/ticket/8485

maybe merge both with both examples

comment:2 Changed 3 years ago by scottgonzalez

#8485 is a duplicate of this ticket.

comment:3 Changed 3 years ago by scottgonzalez

#8486 is a duplicate of this ticket.

comment:4 Changed 3 years ago by Scott González

  • Resolution set to fixed
  • Status changed from new to closed

Dialog: Don't use $.attrFn since it's empty in jQuery 1.8.0. Fixes #8484 - Text of buttons in dialog is not shown with jquery 1.8.0.

Changeset: 5e935ead9fbfb0ab368a9828a4d4b8d17eb38d5c

comment:5 Changed 3 years ago by scottgonzalez

  • Milestone changed from 1.9.0 to 1.8.23

In the meantime, you can either delete $.attrFn; or if ( $.attrFn ) { $.attrFn.text = true; }.

comment:6 Changed 3 years ago by scottgonzalez

#8487 is a duplicate of this ticket.

comment:7 Changed 3 years ago by scottgonzalez

#8488 is a duplicate of this ticket.

comment:8 Changed 3 years ago by scottgonzalez

#8489 is a duplicate of this ticket.

comment:9 follow-up: Changed 3 years ago by staticdream

don't forget you can use the code below after initializing the dialog in the interim without having to modify the actual jquery script! :)

$("#confirm_dialog").parent().find("button[text='Ok']").find("span").html("Ok");

Last edited 3 years ago by staticdream (previous) (diff)

comment:10 in reply to: ↑ 9 Changed 3 years ago by scottgonzalez

Replying to staticdream:

don't forget you can use the code below...

As I mentioned above, a better fix is to just delete $.attrFn after loading jQuery.

comment:11 Changed 3 years ago by scottgonzalez

#8496 is a duplicate of this ticket.

Note: See TracTickets for help on using tickets.