1jQuery(document).ready(function(){ 2 // UL = .wooTabs 3 // Tab contents = .inside 4 5 jQuery( '.pptwj-tabs-wrap .inside ul.list li:last-child').css( 'border-bottom','0px' ); // remove last border-bottom from list in tab content 6 jQuery( '.pptwj-tabs-wrap .tab-links').each(function(){ 7 jQuery(this).children( 'li').children( 'a:first').addClass( 'selected' ); // Add .selected class to first tab on load 8 }); 9 jQuery( '.inside > *').hide(); 10 jQuery( '.inside > *:first-child').show(); 11 12 jQuery( '.pptwj-tabs-wrap .tab-links li a').click(function(evt){ // Init Click funtion on Tabs 13 14 var clicked_tab_ref = jQuery(this).attr( 'href' ); // Strore Href value 15 16 jQuery(this).parent().parent().children( 'li').children( 'a').removeClass( 'selected' ); //Remove selected from all tabs 17 jQuery(this).addClass( 'selected' ); 18 jQuery(this).parent().parent().parent().children( '.inside').children( '*').hide(); 19 20 jQuery( '.inside ' + clicked_tab_ref).fadeIn(500); 21 22 evt.preventDefault(); 23 24 }); 25 26 /** Ajax list filter **/ 27 jQuery( 'ul.tab-filter-list a' ).click( function(e){ 28 var $this = jQuery(this); 29 var $tabWidgetData = { 30 'time' : $this.data('time'), 31 'numberposts' : $this.data('numberposts'), 32 'thumb' : $this.data('thumb'), 33 'tab' : $this.data('tab'), 34 'action' : "pptwj_tabwidget_list" 35 }; 36 37 /** 38 * Display ajax loader/spinner 39 */ 40 var box_height = jQuery('.pptwj-tabs-wrap .boxes').outerHeight(); 41 var spinner = jQuery('.pptwj-loader img'); 42 var spinner_div = jQuery('.pptwj-loader'); 43 44 spinner.css('margin-top', box_height/2); 45 spinner_div.css('height', box_height); 46 spinner_div.show(); 47 48 var $tabWidgetHandler = function( $data ){ 49 //console.log( $data ); 50 spinner_div.hide(); 51 if( $data == "" ) return; 52 53 jQuery('ul.tab-filter-list a').removeClass('selected'); 54 $this.addClass('selected'); 55 56 var $list = $this.parent().parent().siblings('.list'); 57 $list.html( $data ); 58 }; 59 60 jQuery.post( 61 PPTWJ.ajaxUrl, 62 $tabWidgetData, 63 $tabWidgetHandler 64 ); 65 66 e.preventDefault(); 67 }); 68});
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.