PageSourceSearch

https://sarzaminema.ir/wp-content/themes/themerush/js/custom.js?ver=1.6

js sarzaminema.ir collected 2026-10-03 01:23:29 UTC 8,896 bytes, 298 lines download raw bytes

1
2jQuery(document).ready(function ($) {
3
4    //////////////////////////////////////////////////////////////////////////	
5    // News ticker
6    //////////////////////////////////////////////////////////////////////////
7
8	if (jQuery().simplyScroll) {
9    $("#scroller").simplyScroll({
10        autoMode: 'loop',
11        speed: 1,
12        frameRate: 30
13    });
14	}
15
16    //////////////////////////////////////////////////////////////////////////	
17    // Fixed Main Menu
18    //////////////////////////////////////////////////////////////////////////
19	if (jQuery().sticky) {
20	$("#main-menu").sticky({ 
21 	topSpacing: 0 
22	});
23	}
24    //////////////////////////////////////////////////////////////////////////	
25    // Menu
26    //////////////////////////////////////////////////////////////////////////
27    var mainmenu = $('#menu-top, #mainmenu').superfish({
28        delay: 500,
29        animation: {
30            opacity: 'show',
31            height: 'show'
32        },
33        speed: 'fast',
34        autoArrows: false,
35        dropShadows: false,
36        disableHI: true
37        //add options here if required
38    });
39
40
41
42    //////////////////////////////////////////////////////////////////////////	
43    // Hovers images
44    //////////////////////////////////////////////////////////////////////////
45
46    $('.triple img, .review-post img, .widget.rec img, .themeloy-popularpost-widget img, .bi_recent_entries img, .carousel img, .post-tab-home img, .cat_recent_entries img, .flickr_badge_image img, .post-news img, .post a img, .relativepost img, .moreincategories img, .page-full a img, .page-sidebar a img').hover(function () {
47        $(this).stop().animate({
48            opacity: 0.7
49        }, {
50            queue: false,
51            duration: 200
52        });
53    }, function () {
54        $(this).stop().animate({
55            opacity: 1
56        }, {
57            queue: false,
58            duration: 200
59        });
60    });
61
62    //////////////////////////////////////////////////////////////////////////	
63    // Search and Share
64    //////////////////////////////////////////////////////////////////////////
65
66    var $ticker = $("#tickersearchform");
67    var $social = $(".socialdrop");
68    $ticker.data('bSearch', false);
69    $social.data('cSocial', false);
70
71    var closeSearch = function () {
72
73        $ticker.data('bSearch', false);
74        $ticker.slideUp(400, 'easeInOutQuart');
75
76    };
77
78    var openSearch = function () {
79
80        $ticker.data('bSearch', true);
81        $ticker.slideDown(400, 'easeInOutQuart');
82      
83    };
84
85    var $body = $("body");
86    $("#tickersearch").on("click", function (e) {
87        e.preventDefault();
88        e.stopPropagation();
89       var $isSearch = $ticker.data('bSearch');
90        if ($isSearch === true) {
91            closeSearch();
92        } else {
93            openSearch();
94            closeSocial();
95            $ticker.on("click", function (e) {
96                e.stopPropagation();
97            });
98            $body.one("click", function (e) {
99                closeSearch();
100            });
101        }
102    });
103
104    var closeSocial = function () {
105
106        $social.data('cSocial', false);
107        $social.slideUp(400, 'easeInOutQuart');
108    };
109
110    var openSocial = function () {
111
112        $social.data('cSocial', true);
113        $social.slideDown(400, 'easeInOutQuart');
114    };
115
116    $("#tickersocial").on("click", function (e) {
117        e.preventDefault();
118        e.stopPropagation();
119
120        var $cSocial = $social.data('cSocial');
121
122        if ($cSocial === true) {
123            closeSocial();
124        } else {
125            openSocial();
126            closeSearch();
127            $social.on("click", function (e) {
128                e.stopPropagation();
129            });
130            $body.one("click", function (e) {
131                closeSocial();
132            });
133        }
134    });
135
136
137    //////////////////////////////////////////////////////////////////////////	
138    // Flex Slider
139    //////////////////////////////////////////////////////////////////////////	 
140
141    if (jQuery().flexslider) {
142        $('.flexslider').flexslider({
143            animation: "fade",
144            slideshow: true,
145            animationLoop: true,
146            start: function (slider) {
147                $('body').removeClass('loading');
148            }
149        });
150    }
151	
152	//////////////////////////////////////////////////////////////////////////
153	//				Audio / Video
154	//////////////////////////////////////////////////////////////////////////
155	$('audio').mediaelementplayer({
156			audioWidth: '100%'
157		});
158	
159
160    //////////////////////////////////////////////////////////////////////////	
161    // Select menu
162    //////////////////////////////////////////////////////////////////////////
163
164    selectnav('mainmenu', {
165        label: 'Navigation Menu',
166        nested: true,
167        indent: '-'
168    });
169    selectnav('menu-top', {
170        label: 'Navigation Menu',
171        nested: true,
172        indent: '-'
173    });
174
175    //////////////////////////////////////////////////////////////////////////	
176    // Carousel
177    //////////////////////////////////////////////////////////////////////////
178
179    var $itemcarousel = $('.jcarousel');
180    if ($itemcarousel.length) {
181        var caroWidth = 220;
182        $itemcarousel.jcarousel({
183            wrap: 'both',
184            //auto: 2, 
185            animation: 1000,
186            easing: 'easeInOutExpo', //easeInBack, easeOutQuart
187            setupCallback: function (carousel) {
188                carousel.reload();
189            },
190            reloadCallback: function (carousel) {
191                var num = Math.round(carousel.clipping() / caroWidth);
192                carousel.options.scroll = num;
193                carousel.options.visible = num;
194            }
195        });
196
197    }
198
199
200    //////////////////////////////////////////////////////////////////////////	
201    // To top
202    //////////////////////////////////////////////////////////////////////////
203
204    $().UItoTop({
205        scrollSpeed: 800,
206        easingType: 'easeInOutExpo'
207    });
208
209
210    //////////////////////////////////////////////////////////////////////////	
211    // Tab
212    //////////////////////////////////////////////////////////////////////////		
213    var $tabsNav = $('.tabs-nav'),
214        $tabsNavLis = $tabsNav.children('li');
215    $tabsNav.each(function () {
216        var $this = $(this);
217        $this.next().children('.tab-content').stop(true, true).hide()
218            .first().show();
219       $this.children('li').first().addClass('active').stop(true, true).show();
220    });
221    $tabsNavLis.on('click', function (e) {
222        var $this = $(this);
223        $this.siblings().removeClass('active').end()
224            .addClass('active');
225        $this.parent().next().children('.tab-content').stop(true, true).hide()
226            .siblings($this.find('a').attr('href')).fadeIn();
227        e.preventDefault();
228    });
229
230    //////////////////////////////////////////////////////////////////////////	
231    // Alert
232    //////////////////////////////////////////////////////////////////////////
233
234    $(".close").live("click", function () {
235        $(this).parent().fadeOut('slow');
236    });
237	
238
239
240
241
242$(window).load(function () { autoHeight (); });
243
244
245
246
247$(window).resize( function(e) { $(".sidebar_center, .sidebar_content, .sidebar_last").removeAttr("style"); 
248	autoHeight (); });
249
250	function autoHeight () {	
251	
252	var maxHeight;	
253	var lastSidebar;
254	maxHeight = Math.max($(".sidebar_center").height(), $(".sidebar_content").height(), $(".sidebar_last").height());
255	
256	var	$widthWidth  = $(window).width();
257	
258	if($widthWidth >= 960) { 
259		$(".sidebar_center, .sidebar_content, .sidebar_last").height(maxHeight);
260		
261	}else if((	$widthWidth > 745) && (	$widthWidth < 959) ){
262	
263		$(".sidebar_center, .sidebar_content").removeAttr("style");
264		
265		
266		maxHeight = $(".sidebar_center").height() + $(".sidebar_last").height();
267		
268		if( maxHeight > $(".sidebar_content").height()) 
269		{
270			$(".sidebar_content").height(maxHeight);
271				
272			} else {			
273				
274			lastSidebar =  $(".sidebar_content").height() - ($(".sidebar_center").height());
275			$(".sidebar_last").height(lastSidebar);
276		}
277		
278		/* Two columns height */
279		maxCols = Math.max($(".sidebar_center").height(), $(".sidebar_content").height());
280		$(".two-columns-layout .sidebar_center").height(maxCols); 
281		$(".two-columns-layout .sidebar_content").height(maxCols);
282		
283		
284		
285	} else { $(".sidebar_center, .sidebar_content, .sidebar_last").removeAttr("style");}
286	
287	}
288	
289
290
291
292    //////////////////////////////////////////////////////////////////////////	
293    // END SCRIPT
294    //////////////////////////////////////////////////////////////////////////
295});
296
297
298 

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.