PageSourceSearch

https://www.photek.com/wp-content/themes/photek/assets/js/custom.js

js photek.com collected 2026-10-03 23:44:19 UTC 2,720 bytes, 113 lines download raw bytes

1/* Set navigation */
2
3function openNav() {
4  $("#mySidenav").addClass("width80");
5  $("#nav-res").addClass("opacityon");
6  $(".cd-shadow-layer").addClass("displayblock");
7  $(".wrapper").addClass("position-fixed-custom");
8  $("body").addClass("overflow-fixed");
9}
10
11function closeNav() {
12  $("#mySidenav").removeClass("width80");
13  $("#nav-res").removeClass("opacityon");
14  $(".cd-shadow-layer").removeClass("displayblock");
15  $(".wrapper").removeClass("position-fixed-custom");
16  $("body").removeClass("overflow-fixed");
17} 
18
19$(document).ready(function(){ 
20
21  $(".cd-shadow-layer").click(function(){
22    closeNav(); 
23  });
24
25  $(window).scroll(function(){
26    var sticky = $(".header-div");
27		var sticky2 = $("#secnav");
28        scroll = $(window).scrollTop();
29
30      if (scroll >= 450) {
31		sticky.addClass("header-bgcolor slideInDown animated"); 
32		sticky2.addClass("fixed slideInDown animated");  
33
34	  } else {
35       sticky.removeClass("header-bgcolor slideInDown animated");
36       sticky2.removeClass("fixed slideInDown animated");
37		  
38	  } 
39
40  });
41  
42			
43			var sections = $('section.landing_main_li')
44				, nav = $('.iconlists ul')
45				, headermain = $('.header-div')
46				, nav_height = nav.outerHeight() + headermain.outerHeight();
47			
48			$('.iconlists ul li:first-child a').addClass('active');
49
50		$(window).on('scroll', function () {
51		  var cur_pos = $(this).scrollTop();
52		  
53		  sections.each(function() {
54			var top = $(this).offset().top - nav_height,
55				bottom = top + $(this).outerHeight();
56			
57			if (cur_pos >= top && cur_pos <= bottom) {
58			  nav.find('a').removeClass('active');
59			  sections.removeClass('active');
60			  
61			  $(this).addClass('active');
62			  nav.find('a[href="#'+$(this).attr('id')+'"]').addClass('active');
63			}
64		  });
65		});
66		
67		nav.find('a').on('click', function () {
68		  var $el = $(this)
69			, id = $el.attr('href');
70		  
71		  $('html, body').animate({
72			scrollTop: $(id).offset().top - nav_height
73		  }, 500);
74		  
75		  return false;
76		});
77
78
79	
80  
81  
82   var ajaxurl = "<?php echo admin_url('admin-ajax.php'); ?>";
83  $(".subscribe-button").click(function(){
84	var email = $('.email-id').val();
85	if(email){
86		$.ajax({
87			url : 'https://www.photek.com/wp-admin/admin-ajax.php',
88			type : 'POST',
89			data : {action: "get_data",email_id: email}, 
90			dataType : 'json',
91			success : function(response) {
92				console.log(response);
93				$('.messages').css('color','green');
94				$('.messages').html('Thank you for contacting us');
95			}
96		});
97	}else{
98		$('.messages').css('color','red');
99		$('.messages').html('Please enter email id');
100	}
101	
102	});
103});
104
105$('.landing_main_li').click(function(){
106	
107	let landing_id = $(this).attr('id');
108	$('.landing_sub_li_'+landing_id).slideToggle();
109	
110});
111
112
113

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.