Opened 13 years ago

Closed 13 years ago

#3085 closed bug (notabug)

ui.tabs doesnt support json

Reported by: [email protected] Owned by: klaus.hartl
Priority: major Milestone:
Component: ui.tabs Version: 1.5.1
Keywords: ui.tabs json Cc:
Blocked by: Blocking:


when i try do get JSON response for tabs reload i get error : "Node cannot be inserted at the specified point in the


my code :

		$("#example > ul").tabs();
		$("#example > ul").tabs("url",1, 'handle.php');
		$("#example > ul").tabs( { ajaxOptions: {		success : function (data,s)alert(data);},		

					cache: false,							dataType : "json"}

server side code :

echo "{ test : 123 }";

html : i have 2 tabs, 1 loads static html and second load data from server ( $("#example > ul").tabs("url",1, 'handle.php'); ),

what ive discovered - i cannot overwrite function that is called onsuccess ( "ajaxOptions : { succes : function ()... " ) . I looked in the source code of ui.tabs and i found this :

var ajaxOptions = $.extend({}, o.ajaxOptions, {
			url: url,
			success: function(r, s) {				

so is this error is caused becouse on success ui.tabs tries to append to page json data? and why i cant overwrite onsuccess method?. mayby im doing something wrong?

Change History (1)

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

Resolution: invalid
Status: newclosed

We can't allow overriding the success function because we need to use that to perform critical functionality for tabs to work. The page you request for remote tabs is supposed to return the exact HTML you want to insert into the tab's panel.

Note: See TracTickets for help on using tickets.