Opened 11 years ago

Closed 11 years ago

Last modified 10 years ago

#8504 closed bug (fixed)

Ajax in Tabs not passing data in 1.9. beta 1

Reported by: Justin Levene Owned by: Justin Levene
Priority: minor Milestone: git
Component: ui.tabs Version: git (not yet released)
Keywords: Cc:
Blocked by: Blocking:

Description

Passing data through Ajax in tabs doesn't work.

CODE:

$("#tabs").tabs({

cache: true, ajaxOptions: {

type : 'GET', data: "id=2", error: function( xhr, status, index, anchor ) {

$( anchor.hash ).html("ERROR");

}

}

});

Change History (7)

comment:1 Changed 11 years ago by Scott González

Owner: set to Justin Levene
Status: newpending

What is the use case of this? The URL from the tab should be providing the data.

comment:2 Changed 11 years ago by Justin Levene

Status: pendingnew

Above works in all versions of 1.8 but not 1.9

Last edited 11 years ago by Justin Levene (previous) (diff)

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

Status: newpending

That is not a use case.

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

Resolution: fixed
Status: pendingclosed

Tabs: Set ajaxOptions in intial $.ajax() call. Fixes #8504 - Ajax in Tabs not passing data in 1.9. beta 1.

Changeset: af67883226954114ef4782f81d1b6360d6516ee9

comment:5 Changed 11 years ago by Scott González

Milestone: 1.9.0git

I'd still like to know what the use case is for this, but it's important to me to not have 1.9 break any code that works with 1.8, even though ajaxOptions is deprecated.

comment:6 Changed 10 years ago by zap

A possible work case is if you need to send post data. In my case I have a form that needs to be sent when a tab is changed. A workaround to send the data as GET in the url is not possible in my case. Even this ticket is marked as closed I think this is a bug and a fix is needed

beforeLoad: function(event, ui){
ui.ajaxSettings.data = form.serialize();
}

comment:7 Changed 10 years ago by Scott González

zap: Your comment doesn't describe a bug. You want to submit a form when a tab is changed, but I have no idea how that's related to this ticket, which is already fixed (and never existed in a stable release). If you have a different bug to report, please file a new ticket. If you have a feature request, please file a new ticket (but we won't be supporting form submission as a way to handle ajax tabs). If you have a question, please use the forums or StackOverflow.

Note: See TracTickets for help on using tickets.