

	$(document).ready(function() {

		$("#sch_contact_form").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=appointment&caption=Main Top Banner' });
		$("#menu_contact_popupwtf").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Main Menu Contact Us' });

		$("#wp_page_contact_lonk").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Company Page' });
		$("#wp_page_signup_lonk").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=signup&caption=Solutions: ShopsGenie - Hosted Shopping Cart Solution' });

		$("#wp_page_jobberlin_lonk").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Jobs: Berlin' });
		$("#wp_page_jobmunich_lonk").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Jobs: Munich' });
		$("#wp_page_jobregens_lonk").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Jobs: Regensburg' });
		$("#wp_page_joblahore_lonk").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Jobs: Lahore' });

		$("#wp_page_scaleinapp_lonk").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Scalable Internet Applications' });
		$("#wp_page_ecommapp_lonk").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=eCommerce Applications' });
		$("#wp_page_socilmedaapp_lonk").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Social Media Applications' });
		
		$("#wp_page_mobapp_lonk").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Mobile Applications' });
		$("#wp_page_commportal_lonk").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Communities and Portals' });
		$("#wp_page_corporateweb_lonk").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Corporate Websites' });
		$("#wp_page_phpzend_lonk").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=PHP Zend' });
		$("#wp_page_phpsymfony_lonk").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=PHP Symfony' });
		$("#wp_page_aspdotnet_lonk").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=ASP.Net' });
		$("#wp_page_rubyrails_lonk").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Ruby on Rails' });
		$("#wp_page_amazonwebser_lonk").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Amazon Web Services' });
		$("#wp_page_cmsjoomla_lonk").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Joomla' });
		$("#wp_page_cmsdrupal_lonk").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Drupal' });
		$("#wp_page_cmstypo3_lonk").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Typo3' });
		$("#wp_page_iphone_lonk").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=iPhone/iPad Development' });
		$("#wp_page_androiddevelop_lonk").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Android Development' });
		$("#wp_page_nokiaovi_lonk").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Nokia Ovi' });
		$("#wp_page_commagento_lonk").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Magento' });
		$("#wp_page_cvtp_lonk").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Coeus Virtual Team Program' });
		$("#wp_page_servicestartup_lonk").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Services For Startups' });
		$("#wp_page_serviceagencies_lonk").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Services For Agencies' });

		// landing pages popup
		$(".iphone-genre-class").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Home: iPhone/iPad Development' });
		$(".android-genre-class").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Home: Andriod Development' });
		$(".main-facebook-lgo").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Home: Facebook' });
		$(".main-myspace-lgo").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Home: MySpace' });
		$(".main-studivz-lgo").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Home: Studivz' });
		$(".main-hi5-lgo").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Home: Hi5' });
		$(".php-zend-landing-page").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Home: PHP Zend' });
		$(".php-symfony-landing-page").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Home: PHP Symfony' });
		$(".ruby-rails-landing-page").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Home: Ruby on Rails' });
		$(".drupal-landing-page").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Home: Drupal' });
		$(".joomla-landing-page").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Home: Joomla' });
		$(".typo3-landing-page").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Home: Typo3' });
		$(".magnolia-landing-page").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Home: Magnolia' });
		$(".magento-landing-page").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Home: Magento' });
		$(".oscommerce-landing-page").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Home: Oscommerce' });
		$(".aspdotnet-landing-page").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Home: Asp.net' });
		$(".aws-landing-page").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Home: Amazon Web Serivces' });

		//$(".mpopup-contact").colorbox({width:"588px", height:"512px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus' });
		
		// START - For demo purposes only, remove the following line afterwards
		$("#services_ppup_1").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Services: Project planning – AGILE / SCRUM Methodology' });
		$("#services_ppup_2").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Services: Development (PHP, RoR, .NET), testing and deployment' });
		$("#services_ppup_3").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Services: Servers / Cloud Management – Amazon Web services' });
		$("#services_ppup_4").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Services: CVTP has been designed for clients with following requirements' });


		$("#skills_ppup_1").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Skills: Scalable Internet Applications' });
		$("#skills_ppup_2").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Skills: Social Media Applications' });
		$("#skills_ppup_3").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Skills: Communities and Portals' });
		$("#skills_ppup_4").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Skills: eCommerce Applications' });
		$("#skills_ppup_5").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Skills: Mobile Applications' });
		$("#skills_ppup_6").colorbox({width:"588px", height:"515px", iframe:true, overlayClose: false, opacity: 0.5, title:' ', href: coeus_base_url+'?p=236&lang='+current_coes_lang+'&mode=contactus&caption=Skills: Corporate Websites' });
		// END - For demo purposes only, remove the following line afterwards

		// apply google tracking on external links (apply on all links that have class name 'outbound_link')
		google_tracking_external_links();
	});


	function google_tracking_external_links()
	{
		// get all the elements with class 'outbound_link'
		$(".outbound_link").each(function() {
										  
				  //external_url = $(this).attr('href');
				  
				  $(this).click(function() {
				  	
					_gaq.push(['_trackPageview', $(this).attr('href')]);
					  
				  });
  	    });
	}
	
	
  	function checkContactForm()
	{
		$('#ajax_response').html('<img src="'+coeus_theme_base_url+'/images/loading.gif" />');
		form_serial = $("#cform").serialize();
		
		$.ajax({
			  url: coeus_base_url+'/?coe_module=checkform&lang='+current_coes_lang,
			  type: 'POST',
			  data: form_serial,
			  success: function(data) {
				
					po = data.indexOf('all is well');
					$('#ajax_response').html(data);
					
					if (po != -1)
					{						
						jQuery("#cform").attr("onsubmit", "return true;");
						jQuery('#cmd_submit').click();						
						
						//document.frm_cmt.submit();
						//sub_form();
						//return true;
					}		
			  }
		});
		
		return false;
	}
		
	function checkSecondContactForm()
	{
		$('#ajax_response').html('<img src="'+coeus_theme_base_url+'/images/loading.gif" />');
		form_serial = $("#sec_contact_form").serialize();
		
		$.ajax({
			  url: coeus_base_url+'/?coe_module=checksecondform&lang='+current_coes_lang,
			  type: 'POST',
			  data: form_serial,
			  success: function(data) {
				
					$('#ajax_response').html(data);
			  }
		});
		
		return false;
	}
