jqueryjquery-pluginsjquery-tools

Scrollable plugIn questions with jQuery Tools


I am using this plugin with one pane being shown at a time and I have those little circles on top to navigate through each pane.

If I have three panes within my carousel, so therefore against each of these little circle buttons, it assigns 0, 1 and 2 as href values, how can I get access to these href index values when I click on each of these circles?

I basically would like to capture the pane href value I am currently on when clicked but I don't know how to do this or locate onClick event within plugin.

See: http://flowplayer.org/tools/scrollable.html


Solution

  • In the example you given above just use:

    $('div.navi > a').click(function () {
        console.log($(this).attr('href'));
    });