JQuery tabs: spinner option not working

I need ajax animation, and the remote page is bookmarked.

I use

$('#tabs2').tabs({ spinner: ''<img src="../../Content/images/Jquery/spinner.gi'' }); 

Even $('#tabs2').tabs({ spinner: 'Loading..' }); also does not work ...

Although the functionality of the tab works, but the animation does not work ...

I am using jquery theme movie files. Your help is greatly appreciated. Thank you very much

+4
source share
6 answers

Sorry, issue resolved. I will put the <span> on the tabs. Found a solution in jQuery support discussions. http://docs.jquery.com/Discussion

eg.

 <li><a href="../URL">**<span>Text to display in Tabs</span></a></li> <li><a href="tabdiv">**<span>Text to display in Tabs</span></a></li> 
+5
source

If the spinner does not work for you (this is not for me), try the following:

 $("#tabs").tabs({ beforeLoad: function (event, ui) { ui.panel.text('Retrieving data...'); } }); 
+3
source

This first piece of code published does not look right. It should be:

 $('#tabs2').tabs({ spinner: '<img src="../../Content/images/Jquery/spinner.gif"/>' }); 

The second snippet should work fine, assuming that "# tabs2" refers to the container tab, not one of the individual tabs.

Modify your question and post the appropriate HTML for the tabs.

+2
source

The spinner option on jquery.ui tabs is only used when loading remote content using ajax. Are you sure you are using ajax mode, and not just showing and hiding existing content on your tabbed page?

+1
source

I could not understand what the answer was, so again, if someone also could not understand.

The contents of the tab are not displayed at boot time, but the title of the tab. All you have to do is put the tab header in the span tags

front:

 <ul > <li><a href="link.html" >Users</a></li> </ul> 

after

 <ul > <li><a href="link.html" ><span>Users</span></a></li> </ul> 

The tab title should be surrounded by a range, as you can see. Users become <span>Users</span>

+1
source

Adding tab links around the text fixes the problem. Sumanta's solution is correct, but I'm not sure you need the two asterisk characters that are there.

0
source

Source: https://habr.com/ru/post/1286362/


All Articles