    
    var last_block = 1;
    
    $(document).ready(function() {
        $("#chained").scrollable({circular: true, mousewheel: false}).navigator();
        $("#chained-second").scrollable({circular: true, mousewheel: false}).navigator();
    });
    
    $(function() {
        $(".slidetabs").tabs(".images > div.div-item", {
            effect: 'fade',
            fadeOutSpeed: "slow",
            rotate: true
        }).slideshow();
    });
    
    function selectItem(item_id) {
        $(document).ready(function() {
            $('#arrow-1, #arrow-2, #arrow-3, #arrow-4').attr('class', 'not-selected-arrow');    
            $('#arrow-' + item_id).attr('class', 'selected-arrow');
            
            $('#a-1, #a-2, #a-3, #a-4').attr('class', '');    
            $('#a-' + item_id).attr('class', 'selected-a');
            
            if(item_id == 1) {
                $('#first-select').show();
                $('#second-select, #third-select, #fourth-select').hide();
            }
            else if(item_id == 2) {
                $('#second-select').show();
                $('#first-select, #third-select, #fourth-select').hide();
            }
            else if(item_id == 3) {
                $('#third-select').show();
                $('#first-select, #second-select, #fourth-select').hide();
            }
            else if(item_id == 4) {
                $('#fourth-select').show();
                $('#first-select, #third-select, #second-select').hide();
            }
        });
    }
    /*$(function() {
        $("#flowpanes").scrollable({ circular: true, mousewheel: false }).navigator({
            navi: "#flowtabs",
            naviItem: 'a',
            activeClass: 'current',
            history: true
        });
    });*/
