PageSourceSearch

https://diabloperkele.com/wp-content/themes/ironband/js/main.js?t=1739134272

js diabloperkele.com collected 2026-10-02 12:35:01 UTC 22,330 bytes, 895 lines download raw bytes

1var iron_vars = window.iron_vars || {}
2,   IronBand = window.IronBand || {};
3
4(function($){
5	"use strict";
6
7	IronBand.$ = window.IronBand.$ || {};
8
9	IronBand.XHR = {
10		settings: {
11			  url  : iron_vars.ajaxurl
12			, type : 'POST'
13		}
14	};
15
16	var jcf = window.jcf || {};
17	var DocumentTouch = window.DocumentTouch || {};
18	var ResponsiveHelper = window.ResponsiveHelper || {};
19	var jPlayerPlaylist = window.jPlayerPlaylist || {};
20	var PlaceholderInput = window.PlaceholderInput || {};
21	var TouchNav = window.TouchNav || {};
22	var lib = window.lib || {};
23
24	// page init
25	jQuery(function(){
26		IronBand.initNavigationSelect();
27		jcf.customForms.replaceAll();
28		IronBand.initTouchNav();
29		IronBand.initAccordion();
30		IronBand.initPopups();
31		IronBand.initInputs();
32		IronBand.initFitVids();
33		IronBand.initDropDownClasses();
34		IronBand.initMobileSubMenus();
35		IronBand.initPlayer();
36		IronBand.initAjaxBlocksLoad();
37		IronBand.initSliderRevolution();
38		IronBand.initLightbox();
39		IronBand.initAnchorGigs();
40		IronBand.initCarousel();
41		IronBand.initLayout();
42		IronBand.initQuicksand();
43		IronBand.initNewsLetter();
44		IronBand.initFacebookLikebox();
45		IronBand.initTwitter();
46
47		if(iron_vars.enable_fixed_header)
48			IronBand.initFixedBar();
49
50		if(iron_vars.enable_nice_scroll)
51			IronBand.initNiceScroll();
52
53		/* Fancybox overlay fix */
54		// detect device type
55		var isTouchDevice = (function() {
56			try {
57				return ('ontouchstart' in window) || window.DocumentTouch && document instanceof DocumentTouch;
58			} catch (e) {
59				return false;
60			}
61		}());
62
63		// fix options
64		var supportPositionFixed = !( (jQuery.browser.msie && jQuery.browser.version < 8) || isTouchDevice );
65		var overlaySelector = '#fancybox-overlay';
66
67		if(supportPositionFixed) {
68			// create <style> rules
69			var head = document.getElementsByTagName('head')[0],
70				style = document.createElement('style'),
71				rules = document.createTextNode(overlaySelector+'{'+
72					'position:fixed;'+
73					'top:0;'+
74					'left:0;'+
75				'}');
76
77			// append style element
78			style.type = 'text/css';
79			if(style.styleSheet) {
80				style.styleSheet.cssText = rules.nodeValue;
81			} else {
82				style.appendChild(rules);
83			}
84			head.appendChild(style);
85		}
86	});
87
88	jQuery(window).load(function(){
89		setTimeout(function(){
90			IronBand.initSameHeight();
91			jQuery(window).trigger('resize');
92		}, 200);
93	});
94
95	IronBand.pagination = {
96		  XHR: {}
97		, $: {}
98		, loadingClass: 'ajax-load'
99		, ajaxBusy: false
100	};
101
102	IronBand.pagination.XHR = {
103		done: function ( response, status, xhr ) { // success : data, status, xhr
104
105			var IB = IronBand.pagination;
106
107			if ( response/* && response.output != ''*/ )
108			{
109                IB.$.container.append(response).fadeIn();
110
111				var newMoreButton = IB.$.container.find('.button-more');
112				if(newMoreButton.length > 0) {
113					IB.$.loadButton.replaceWith(newMoreButton[0].outerHTML );
114					newMoreButton.remove();
115					IB.$.loadButton = $('.button-more');
116					
117				}else{
118					IB.$.loadButton.remove();
119				}
120				
121				
122				IB.ajaxBusy = false;
123
124				IronBand.initTouchNav();
125
126				var callbacks = IB.$.loadButton.data('callback');
127				if ( callbacks ) {
128					callbacks = callbacks.split(',');
129
130					for ( var i = 0 ; i < callbacks.length ; i++ )
131					{
132						var callback = IronBand[callbacks[i]];
133
134						if ( typeof callback === 'function' ) {
135							callback();
136						}
137					}
138				}
139
140				if ( IB.method == 'paginate_scroll' ) {
141
142					$(window).on('scroll', function ( event ) {
143						if ( ! IB.ajaxBusy ) {
144							var $win = $(window)
145							,   $doc = $(document)
146							,   $foot = $('body > footer');
147
148							if ( $win.scrollTop() >= ($doc.height() - $win.height() - ( $foot.height() ) ) ) {
149								IB.$.loadButton.click();
150							}
151						}
152					});
153
154				} else {
155					IB.$.loadButton.css('visibility', 'visible').fadeIn();
156				}
157
158			} else {
159
160				IB.$.loadButton.remove();
161				IB.XHR.fail( xhr, 'error', 404 );
162			}
163		}
164		, fail: function ( xhr, status, error ) { // error : xhr, status, error
165
166			var IB = IronBand.pagination;
167
168			setTimeout(function() {
169				alert( IB.$.loadButton.data('warning') );
170			}, 100);
171		}
172		, always: function () { // complete : data|xhr, status, xhr|error
173
174			var IB = IronBand.pagination;
175			IB.$.loadButton.prop('disabled', false);
176
177			IB.$.container.removeClass(IB.loadingClass);
178
179			if ( iron_vars.enable_nice_scroll && !jcf.isTouchDevice )
180				IronBand.niceScroll.resize();
181		}
182		, before: function ( xhr ) {
183
184			var IB = IronBand.pagination;
185			IB.$.loadButton.prop('disabled', true);
186		}
187	};
188
189	IronBand.initAnchorGigs = function () {
190		jQuery('ul.concerts-list .open-link').each(function(){
191			var opener = jQuery(this);
192			if(window.location.href.indexOf(opener.attr('id')) > 0) {
193				jQuery(window).scrollTop(opener.offset().top - 100);
194				opener.trigger('click');
195			}
196		});
197	}
198
199	IronBand.initLayout = function () {
200		var visibleElements;
201		ResponsiveHelper.addRange({
202			'..499': {
203				on: function () {
204					IronBand.updateCarousel(1, 'all');
205				}
206			},
207			'500..899': {
208				on: function () {
209					IronBand.updateCarousel(2, 'wide');
210				}
211			},
212			'500..767': {
213				on: function () {
214					IronBand.updateCarousel(2, 'narrow');
215				}
216			},
217			'768..': {
218				on: function () {
219					IronBand.updateCarousel(1, 'narrow');
220				}
221			},
222			'900..': {
223				on: function () {
224					IronBand.updateCarousel(3, 'wide');
225				}
226			}
227		});
228	}
229
230	IronBand.initSliderRevolution = function () {
231		IronBand.$.marquee = jQuery('#home-marquee');
232
233		if ( jQuery.fn.cssOriginal != undefined )
234			jQuery.fn.css = jQuery.fn.cssOriginal;
235
236		IronBand.$.marquee
237			.revolution({
238				  delay            : 5000
239				, startheight      : 500
240				, startwidth       : 1144
241
242				, navigationType   : 'none'	// bullet, thumb, none
243				, navigationArrows : 'none'	// nexttobullets, solo (old name verticalcentered), none
244
245				, touchenabled     : 'on'	// Enable Swipe Function : on/off
246				, onHoverStop      : 'on'	// Stop Banner Timet at Hover on Slide on/off
247
248				, stopAtSlide      : -1
249				, stopAfterLoops   : -1
250
251				, shadow           : 1		//0 = no Shadow, 1,2,3 = 3 Different Art of Shadows  (No Shadow in Fullwidth Version !)
252				, fullWidth        : 'on'	// Turns On or Off the Fullwidth Image Centering in FullWidth Modus
253			})
254			.bind('revolution.slide.onloaded',function () {
255				// jQuery('.marquee').css('height', 'inherit');
256
257				// Put caption text on 2 lines
258				jQuery('.slide .caption h1').each(function() {
259					var $this = jQuery(this)
260					,   text  = $this.text()
261					,   words = text.split(' ')
262					,   half  = Math.ceil(words.length / 2)
263					,   line1 = ''
264					,   line2 = ''
265					,   i;
266
267					for ( i = 0; i < half; i++ )
268					{
269						line1 += words[i];
270						if ( i < half - 1 ) {
271							line1 += ' ';
272						}
273					}
274
275					for ( i = half; i < words.length; i++ )
276					{
277						line2 += words[i];
278						if ( i < words.length - 1 ) {
279							line2 += ' ';
280						}
281					}
282
283					var html = '';
284
285					if ( line1 !== '' ) {
286						html += '<span>' + line1 + '</span>';
287					}
288
289					if ( line2 !== '' ) {
290						html += '<span>' + line2 + '</span>';
291					}
292
293					$this.html(html);
294				});
295				
296				setTimeout(function() {
297					
298					$('.tp-rightarrow').on('tap', function() {
299						IronBand.$.marquee.revnext();
300					});
301					$('.tp-leftarrow').on('tap', function() {
302						IronBand.$.marquee.revprev();
303					});
304
305				}, 1000);
306		});
307	}
308
309	IronBand.initFacebookLikebox = function () {
310		if($('#fb-likebox').length === 0) {
311			return false;
312		}
313
314		var fb_app_id = $('#fb-likebox').data('appid');
315		var fb_page_url = $('#fb-likebox').data('pageurl');
316		fb_page_url = encodeURI(fb_page_url);
317
318		var iframe = '<iframe src="//www.facebook.com/plugins/likebox.php?href='+fb_page_url+'&amp;width=200&amp;height=62&amp;show_faces=false&amp;colorscheme=dark&amp;stream=false&amp;border_color&amp;header=false&amp;appId='+fb_app_id+'" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:200px; height:62px;" allowTransparency="true"></iframe>';
319
320		$('#fb-likebox').html(iframe);
321	}
322
323
324	IronBand.initTwitter = function () {
325		if($('#twitter').length === 0) {
326			return false;
327		}
328
329		var username = $('#twitter').data('username');
330
331		jQuery(function($){
332			$('#twitter').tweet({
333				modpath: iron_vars.theme_url+'/js/twitter/',
334				join_text: 'auto',
335				username: (username ? username : 'envato'),
336				count: 1,
337				auto_join_text_default: '',
338				auto_join_text_ed: '',
339				auto_join_text_ing: '',
340				auto_join_text_reply: '',
341				auto_join_text_url: '',
342				loading_text: 'loading tweets...'
343			}).bind('loaded', function() {
344				jQuery(window).resize();
345			});
346		});
347	}
348
349	IronBand.initNiceScroll = function () {
350		$(document).ready(function() {
351			IronBand.niceScroll = $('html').niceScroll();
352		});
353	}
354
355	IronBand.carousel = {
356		  enabled: false
357		, defaults: {
358			all: {
359				  circular    : true
360				, responsive  : true
361				, width       : '100%'
362				, scroll      : 1
363				, auto        : false
364				, items       : {
365					  visible : 'variable'
366					, height  : 'auto'
367				}
368				, onCreate    : function ( data ) {
369					var $this = $(data.items.context);
370
371					$this.addClass('js-carousel');
372				}
373			}
374			, wide: {
375				items: {
376					visible: 3
377				}
378			}
379			, narrow: {
380				items: {
381					visible: 1
382				}
383			}
384		}
385		, settings: {
386			  wide : {}
387			, narrow  : {}
388		}
389		, $: {
390			carousels: {
391				  all    : null
392				, wide   : null
393				, narrow : null
394			}
395		}
396	};
397
398	IronBand.initCarousel = function () {
399
400		var IB = IronBand.carousel;
401
402		IB.$.carousels.all    = $('.carousel');
403		IB.$.carousels.wide   = IB.$.carousels.all.not(':parents(.content__side)').not(':parents(.grid-cols--2)');
404		IB.$.carousels.narrow = IB.$.carousels.all.filter(':parents(.content__side)').add( IB.$.carousels.all.filter(':parents(.grid-cols--2)') );
405
406		IB.settings.wide = $.extend(true, {}, IB.defaults.all, IB.defaults.wide );
407		IB.settings.narrow  = $.extend(true, {}, IB.defaults.all, IB.defaults.narrow );
408
409		if ( IB.$.carousels.all.length )
410		{
411			IB.enabled = true;
412
413			IB.$.carousels.wide.each(function () {
414				var $this = $(this)
415				,   options = {
416					prev: {
417						button: $this.find('.btn-prev')
418					}
419					, next: {
420						button: $this.find('.btn-next')
421					}
422				}
423				,   settings = $.extend(true, IB.settings.wide, options);
424
425				$this.find('.slideset').carouFredSel( settings );
426			});
427
428			IB.$.carousels.narrow.each(function () {
429				var $this = $(this)
430				,   options = {
431					prev: {
432						button: $this.find('.btn-prev')
433					}
434					, next: {
435						button: $this.find('.btn-next')
436					},
437				}
438				,   settings = $.extend(true, IB.settings.narrow, options);
439
440				$this.find('.slideset').carouFredSel( settings );
441			});
442		}
443	}
444
445	IronBand.updateCarousel = function ( visibleElements, collection ) {
446
447		var IB = IronBand.carousel;
448
449		if ( typeof collection !== 'string' )
450			collection = 'all';
451
452		if ( IB.enabled )
453		{
454			IB.$.carousels[ collection ].each(function(){
455				var $this = $(this);
456				$this.find('.slideset').trigger('configuration', ['items.visible', visibleElements, true]);
457			});
458		}
459	}
460
461	IronBand.initFixedBar = function () {
462		var win = jQuery(window);
463		var animSpeed = 500;
464		var activeClass = 'fixed-bar';
465		var clone;
466		jQuery('.panel').each(function(){
467			var panel = jQuery(this);
468			function getPosition(){
469				var offset = jQuery('#header').outerHeight(true);
470				if(win.scrollTop() > offset) {
471					if(!clone) {
472						clone = true;
473						var panelHeight = panel.outerHeight();
474						clone = panel.clone( true, true );
475						clone.insertAfter(panel).addClass(activeClass).css({
476							'opacity': 0,
477							'marginTop': -panelHeight
478						}).animate({
479							'opacity': 1,
480							'marginTop': 0
481						}, {
482							duration: animSpeed,
483							queue: false
484						});
485						IronBand.initTouchNav();
486					}
487				}
488				else {
489					if (clone) {
490						clone.remove();
491						clone = false;
492					}
493				}
494			}
495			getPosition();
496			win.bind('scroll resize', getPosition);
497		});
498	}
499
500    IronBand.initAjaxBlocksLoad = function() {
501
502        IronBand.pagination.XHR.request = {
503            dataType: 'text',
504            data: {
505	            ajax: 1
506            },
507			beforeSend: IronBand.pagination.XHR.before
508        };
509
510        IronBand.pagination.XHR.request = $.extend(true, IronBand.pagination.XHR.request, IronBand.XHR.settings);
511		IronBand.initAjaxBlocksLoadEvent(); 
512
513        $('a.button-more').trigger('click');
514
515    }
516    
517    IronBand.initAjaxBlocksLoadEvent = function() {
518	    
519
520		$(document).off('click', 'a.button-more');
521        $(document).on('click', 'a.button-more', function(e) {
522            e.preventDefault();
523
524            var IB = IronBand.pagination
525                    , $this = $(this);
526
527			IB.isotope = ($('.isotope-wrap').length > 0);
528			
529            if (IB.ajaxBusy)
530                return;
531
532            IB.$.loadButton = $this;
533            IB.$.container = $('#' + IB.$.loadButton.data('rel'));
534            IronBand.pagination.XHR.request.url = IB.$.loadButton.attr('href');
535            IronBand.XHR.settings.url = IB.$.loadButton.attr('href');
536
537            IB.method = $this.data('paginate');
538
539            $.ajax(IB.XHR.request)
540                    .done(IB.XHR.done)
541                    .fail(IB.XHR.fail)
542                    .always(IB.XHR.always);
543        });	    
544    }
545
546	// add classes if item has dropdown
547	IronBand.initDropDownClasses = function () {
548		jQuery('#nav li').each(function() {
549			var item = jQuery(this);
550			var drop = item.find('ul');
551			var link = item.find('a').eq(0);
552			if(drop.length) {
553				item.addClass('has-drop-down');
554				if(link.length && item.hasClass('menu-item-has-children')) { link.addClass('has-drop-down-a'); }
555			}
556		});
557	}
558	
559	// Toggle sub-menus on mobile
560	IronBand.initMobileSubMenus = function () {
561		$('.has-drop-down-a').on("click", function(event){
562			if($(window).innerWidth() < 768 ){
563				event.preventDefault();
564				var t = $(this);
565				t.next('.sub-menu').toggle();
566			}
567		});
568	}
569	IronBand.initPlayer = function () {
570		jQuery('.player-holder').each(function(ind){
571			var set = jQuery(this);
572			var dataUrl = set.attr('data-url-playlist');
573            var autoplay = set.attr('data-autoplay');
574			var posterImage = set.find('.poster-image');
575			var defURl = posterImage.attr('src');
576			var titleBox = set.find('.player-title-box');
577			var player = set.find('.jp-jplayer');
578			var playerBox = set.find('.player-box');
579			var uiPlayer = 'jplayer-custom-' + new Date().getMilliseconds() + ind;
580			var uiPlayerBox = 'jplayerBox-custom-' + new Date().getMilliseconds() + ind;
581			var Playlist = {};
582
583			player.attr('id', uiPlayer);
584			playerBox.attr('id', uiPlayerBox);
585
586			jQuery.ajax({
587				url: dataUrl,
588				type: 'get',
589				dataType: 'script',
590				success: function(){
591					startPlayer(autoplay);
592				}
593			});
594
595			function startPlayer(autoplay){
596				Playlist = new jPlayerPlaylist({
597					jPlayer: '#' + uiPlayer,
598					cssSelectorAncestor: '#' + uiPlayerBox
599				}, musicPlayList || [], {
600					swfPath: iron_vars.theme_url+'/js/',
601					supplied: 'mp3',
602					wmode: 'window',
603					ready: function(){
604						refreshInfo();
605						if(autoplay) {
606	                        playerBox.find('.jp-play').click();
607                        }
608					},
609					play: function(){
610						refreshInfo();
611					}
612				});
613			}
614
615			function refreshInfo(){
616				if ( Playlist.original.length )
617				{
618					if ( Playlist.original[Playlist.current].poster ) {
619						posterImage.attr('src', Playlist.original[Playlist.current].poster);
620					} else {
621						posterImage.attr('src', defURl);
622					}
623
624					if ( Playlist.original[Playlist.current].title ) {
625						titleBox.html(Playlist.original[Playlist.current].title);
626					}
627				}
628			}
629		});
630
631		jQuery('.tracks-list li').each(function(ind){
632			var set = jQuery(this);
633			var player = set.find('.jp-jplayer');
634			var playerBox = set.find('.player-box');
635			var playBtn = set.find('.buttons .btn-play');
636			// var pauseBtn = set.find('.buttons .btn-pause');
637			var urlMedia = set.attr('data-media');
638			var uiPlayer = 'jplayer-custom-' + new Date().getMilliseconds() + ind;
639			var uiPlayerBox = 'jplayerBox-custom-' + new Date().getMilliseconds() + ind;
640			player.attr('id', uiPlayer);
641			playerBox.attr('id', uiPlayerBox);
642			if(urlMedia){
643				var urlTag = urlMedia.substr(urlMedia.lastIndexOf('.')+1);
644				var obj = {};
645				obj[urlTag] = urlMedia;
646				jQuery('#' + uiPlayer).jPlayer({
647					cssSelectorAncestor: '#' + uiPlayerBox,
648					ready: function () {
649						jQuery(this).jPlayer('setMedia', obj);
650					},
651					swfPath: iron_vars.theme_url+'/js/',
652					supplied: urlTag,
653					wmode: 'window',
654					solution: "html,flash",
655				});
656
657				var allPauseBtns = jQuery('.tracks-list li').not(set).find('.buttons .btn-pause');
658
659				playBtn.click(function() {
660					allPauseBtns.click();
661				});
662			}
663		});
664	}
665
666	// handle flexible video size
667	IronBand.initFitVids = function () {
668		jQuery('.video-block').fitVids();
669	}
670
671	// accordion menu init
672	IronBand.initAccordion = function () {
673		jQuery('.concerts-list').slideAccordion({
674			activeClass: 'expanded',
675			opener: 'a.open-link',
676			slider: 'div.slide',
677			animSpeed: 300
678		});
679	}
680
681	// popups init
682	IronBand.initPopups = function () {
683		jQuery('.panel').contentPopup({
684			mode: 'click',
685			popup: '.nav-holder',
686			btnOpen: '.opener'
687		});
688	}
689
690	// clear inputs on focus
691	IronBand.initInputs = function () {
692		PlaceholderInput.replaceByOptions({
693			// filter options
694			clearInputs: true,
695			clearTextareas: true,
696			clearPasswords: true,
697			skipClass: 'default',
698
699			// input options
700			wrapWithElement: false,
701			showUntilTyping: false,
702			getParentByClass: false,
703			placeholderAttr: 'value'
704		});
705	}
706
707	// align blocks height
708	IronBand.initSameHeight = function () {
709		jQuery('.widget-area.grid-cols').sameHeight({
710			  elements  : '.widget'
711			, flexible  : true
712			, multiLine : true
713		});
714	}
715
716	// handle dropdowns on mobile devices
717	IronBand.initTouchNav = function () {
718		lib.each(lib.queryElementsBySelector('#nav'), function(){
719			new TouchNav({
720				navBlock: this
721			});
722		});
723		lib.each(lib.queryElementsBySelector('.articles-section .article'), function(){
724			new TouchNav({
725				navBlock: this,
726				menuItems: 'div',
727				menuOpener: 'a',
728				menuDrop: ''
729			});
730		});
731		lib.each(lib.queryElementsBySelector('.concerts-list li'), function(){
732			new TouchNav({
733				navBlock: this,
734				menuItems: 'div.title-row',
735				menuOpener: 'a',
736				menuDrop: ''
737			});
738		});
739		lib.each(lib.queryElementsBySelector('.listing-section'), function(){
740			new TouchNav({
741				navBlock: this,
742				menuItems: 'a',
743				menuOpener: 'a',
744				menuDrop: ''
745			});
746		});
747		lib.each(lib.queryElementsBySelector('.carousel'), function(){
748			new TouchNav({
749				navBlock: this,
750				menuItems: 'a',
751				menuOpener: 'a',
752				menuDrop: ''
753			});
754		});
755		lib.each(lib.queryElementsBySelector('.carousel'), function(){
756			new TouchNav({
757				navBlock: this,
758				menuItems: 'a',
759				menuOpener: 'a',
760				menuDrop: 'div.hover-box'
761			});
762		});
763		lib.each(lib.queryElementsBySelector('.article'), function(){
764			new TouchNav({
765				navBlock: this,
766				menuItems: 'a',
767				menuOpener: 'a',
768				menuDrop: ''
769			});
770		});
771		lib.each(lib.queryElementsBySelector('.photos-list'), function(){
772			new TouchNav({
773				navBlock: this,
774				menuItems: 'li',
775				menuOpener: 'a',
776				menuDrop: 'span.hover-text'
777			});
778		});
779	}
780
781	// generate select from navigation
782	IronBand.initNavigationSelect = function () {
783		jQuery('.filters-block .holder ul').navigationSelect({
784			defaultOptionAttr: 'title',
785			useDefaultOption: false
786		});
787	}
788
789
790	IronBand.initQuicksand = function () {
791
792		if ( $('#filter-type').length < 1 )
793			return;
794
795		var $filterType = $('#filter-type a')
796		,   $collection = $('#filter-collection')
797		,   $data = $collection.clone();		// Clone items to get a second collection
798
799		// Attempt to call Quicksand on every filter click
800		$(document).on('click', $filterType.selector, function (e) {
801			e.preventDefault();
802
803			var $this = $(this);
804
805			$filterType.removeClass('active');
806			$this.addClass('active');
807
808			var $filteredData = $data.find( 'all' === $this.data('target') ? 'li' : 'li[class*="' + $this.data('target') + '"]' );
809
810			$collection.quicksand($filteredData, {
811				  duration    : 600
812				, adjustWidth : false
813				, attribute   : 'id'
814				, easing      : 'easeInOutQuad'
815			},
816			function () {
817				IronBand.initLayout();
818				IronBand.initTouchNav();
819				IronBand.initLightbox();
820				$(window).resize();
821			});
822
823		});
824
825	}
826
827	IronBand.initNewsLetter = function () {
828		// init subscribe form
829		$('.iron_widget_newsletter form').submit(function (event) {
830			event.preventDefault();
831			var form = $(this);
832			var postData = form.serialize();
833			var success = form.find('label');
834			var status = form.find('.form-status');
835
836			$.ajax({
837				type: 'POST',
838				url: iron_vars.ajaxurl,
839				data: postData,
840				success: function(data) {
841
842					if (data === 'success') {
843					
844						form.find('.box').hide();
845						if(success.length > 0) {
846							success.html(iron_vars.lang.newsletter_success).slideDown();
847							status.hide();
848						}else{
849							status.html(iron_vars.lang.newsletter_success).slideDown();	
850												}
851					} else if (data === 'subscribed') {
852						status.html(iron_vars.lang.newsletter_exists).slideDown();
853
854					} else if (data === 'invalid') {
855						status.html(iron_vars.lang.newsletter_invalid).slideDown();
856
857					} else if (data === 'disabled') {
858						status.html('The newsletter module is disabled. You can activate it from within the theme options').slideDown();
859
860					} else if (data === 'missing_api_key') {
861						status.html('Error: Missing Mailchimp API Key / List ID').slideDown();
862
863					} else {
864						status.html(iron_vars.lang.newsletter_error).slideDown();
865					}
866
867				},
868				error: function () {
869					status.html(iron_vars.lang.newsletter_error).slideDown();
870				}
871			});
872		});
873	}
874
875	// fancybox modal popup init
876	IronBand.initLightbox = function () {
877		jQuery('a.lightbox, a[rel*="lightbox"]').fancybox({
878			padding: 10,
879			cyclic: false,
880			overlayShow: true,
881			overlayOpacity: 0.65,
882			overlayColor: '#000000',
883			titlePosition: 'inside'
884		});
885	}
886	
887	$(document).ready(function(){
888		if( /Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)){
889			var logowidth = $('.logo-desktop').width();
890			$('.site-title, .footer-logo').addClass('retina');
891			$('.logo-retina').width(logowidth);
892		}
893	});
894
895})(jQuery);

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.