jQuery: The Write Less, Do More JavaScript Library

binding to tab show events per tab on the tab ui plugin

View: New views
3 Messages — Rating Filter:   Alert me  

binding to tab show events per tab on the tab ui plugin

by Deuce868 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I'm trying to work with the tabs plugin to be able to link to the
specific tabs on the page. I know I can do url.php#someid, but my tabs
have onclick events right now that load the page content.

What I was trying to do was find a way to move from onclick to
tabsshow events bound. My hope was that when the page was loaded via
the #someid url that it would fire the event.

Looking at the docs and testing around a bit, the tabsshow seems to be
an event on the tab grouping vs the individual tabs. Am I missing
something here? Do I need to write a handler within the tabsshow event
to fire off the ajax call for the tab that is currently selected? Does
anyone know if there's a built in way I'm missing to do this already?

--

You received this message because you are subscribed to the Google Groups "jQuery UI" group.
To post to this group, send email to jquery-ui@....
To unsubscribe from this group, send email to jquery-ui+unsubscribe@....
For more options, visit this group at http://groups.google.com/group/jquery-ui?hl=en.



Re: binding to tab show events per tab on the tab ui plugin

by Klaus Hartl-4 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Did not quite understand the problem yet.

The tabsshow event fires on a single tab, and it is fired after the
tabsload event, e.g. after the ajax request. The sequence is selected
- load - show, which is why I don't understand why you want/would have
to to fire that ajax manually.


--Klaus




On 5 Nov., 17:42, Rick Harding <deuce...@...> wrote:

> I'm trying to work with the tabs plugin to be able to link to the
> specific tabs on the page. I know I can do url.php#someid, but my tabs
> have onclick events right now that load the page content.
>
> What I was trying to do was find a way to move from onclick to
> tabsshow events bound. My hope was that when the page was loaded via
> the #someid url that it would fire the event.
>
> Looking at the docs and testing around a bit, the tabsshow seems to be
> an event on the tab grouping vs the individual tabs. Am I missing
> something here? Do I need to write a handler within the tabsshow event
> to fire off the ajax call for the tab that is currently selected? Does
> anyone know if there's a built in way I'm missing to do this already?

--

You received this message because you are subscribed to the Google Groups "jQuery UI" group.
To post to this group, send email to jquery-ui@....
To unsubscribe from this group, send email to jquery-ui+unsubscribe@....
For more options, visit this group at http://groups.google.com/group/jquery-ui?hl=en.



Re: binding to tab show events per tab on the tab ui plugin

by Deuce868 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message



On Nov 6, 2:05 pm, Klaus Hartl <klaus.ha...@...> wrote:
> Did not quite understand the problem yet.
>
> The tabsshow event fires on a single tab, and it is fired after the
> tabsload event, e.g. after the ajax request. The sequence is selected
> - load - show, which is why I don't understand why you want/would have
> to to fire that ajax manually.
>
> --Klaus

Sorry, I originally thought the tabsshow event was specific to each
tab in the grouping. i.e. if I clicked on tab #2 that there was a
tabsshow on #2 that was fired. In essence I was trying to move the
onclick event for each tab heading to a tabsshow for each one.

I've figured out the tabsshow is on the container and that I need to
check the id of the tab in the event to know which one was clicked/
loaded.

Rick

--

You received this message because you are subscribed to the Google Groups "jQuery UI" group.
To post to this group, send email to jquery-ui@....
To unsubscribe from this group, send email to jquery-ui+unsubscribe@....
For more options, visit this group at http://groups.google.com/group/jquery-ui?hl=.