$(document).ready(function(){
		var divShow = 0;
                var divShow1 = 0;
		var divShow2 = 0;
		var originalFontSize = $('body').css('font-size');			
		$('#weatherChart').hide();
                var TourID = $('#txtTourID').val();
		$('input, select') .not(':button, :submit, :reset, :hidden').val('');
		$("#txtTourID").val(TourID);
		$('.submit') .val('Submit');
		$("#chkDates").attr('checked',false);
		$('#selTour').append(new Option('Select tour', '', true, true));
		$('#temp_city').html('');
		$('#widgetControllor').hide();				
		$("#featured > ul").tabs({fx:{opacity: 'toggle', duration:1}}).tabs("rotate", 4000, true);		
                $("#tourSlideshow > ul").tabs({fx:{opacity: 'toggle', duration:1}}).tabs("rotate", 4000, true);
		$("#currConverter").click(function() {
			gp_convertIt();
		});			
		$("#hideTools").click(function() {
			$('#floatingWidget').hide("slide", { direction: "down" }, "fast");
			$('#widgetControllor').show("slide", { direction: "down" }, "fast");
			return false;			
		});		
		$("#share").click(function() {						   
			if (divShow == 0) {				
				$('#dspmail').show("slide", { direction: "down" }, 500);
				divShow = 1;
			}
			/*else
			{
				$('#dspmail').hide("slide", { direction: "down" }, 500);				
				divShow = 0;				
			}*/
			return false;			
		});
		$(".dspmailHide").click(function() {
			$('#dspmail').hide("slide", { direction: "down" }, 500);				
			divShow = 0;
			return false;
		});

         $("#newsletter").click(function() {
			if (divShow1 == 0) {
				$('#dspnews').show("slide", { direction: "down" }, 500);
				divShow1 = 1;
			}
			/*else
			{
				$('#dspnews').hide("slide", { direction: "down" }, 500);
				divShow1 = 0;
			}*/
			return false;
		});
		 $(".dspnewsHide").click(function() {
			$('#dspnews').hide("slide", { direction: "down" }, 500);				
			divShow1 = 0;
			return false;
		});
		
		$("#rqstBrochure").click(function() {						   
			if (divShow2 == 0) {				
				$('#dspbrochure').show("slide", { direction: "down" }, 500);
				divShow2 = 1;
			}
			/*else
			{
				$('#dspbrochure').hide("slide", { direction: "down" }, 500);				
				divShow2 = 0;				
			}*/
		
			return false;
		});
		$(".dspbrochureHide").click(function() {
			$('#dspbrochure').hide("slide", { direction: "down" }, 500);				
			divShow2 = 0;
			return false;
		});
		
		//----------------- Tab Script Starts ---------------------
		
		$(".itinerary").click(function() {
			$('#price, #dates, #map, #tour1, #tour2, #tour3').hide();
			$('.price, .dates, .map, .tour1, .tour2, .tour3').removeClass('active');	 						   
			$(this).addClass('active');	  
			$('#itinerary').show();	  			
			return false;			
		});
		$(".dates").click(function() {
			$('#price, #itinerary, #map, #tour1, #tour2, #tour3').hide();
			$('.price, .itinerary, .map, .tour1, .tour2, .tour3').removeClass('active');
			$(this).addClass('active');	  
			$('#dates').show();	  
			return false;			
		});
		$(".price").click(function() {
			$('#itinerary, #dates, #map, #tour1, #tour2, #tour3').hide();
			$('.itinerary, .dates, .map, .tour1, .tour2, .tour3').removeClass('active');					   
			$(this).addClass('active');	  
			$('#price').show();	  				 
			return false;			
		});
		$(".map").click(function() {
			$('#itinerary, #dates, #price, #tour1, #tour2, #tour3').hide();
			$('.itinerary, .dates, .price, .tour1, .tour2, .tour3').removeClass('active');					   
			$(this).addClass('active');	  
			$('#map').show();	  				 
			return false;			
		});
		$(".tour1").click(function() {
			$('#itinerary, #dates, #price, #map, #tour2, #tour3').hide();
			$('.itinerary, .dates, .price, .map, .tour2, .tour3').removeClass('active');					   
			$(this).addClass('active');	  
			$('#tour1').show();	  				 
			return false;			
		});
		$(".tour2").click(function() {
			$('#itinerary, #dates, #price, #map, #tour1, #tour3').hide();
			$('.itinerary, .dates, .price, .map, .tour1, .tour3').removeClass('active');					   
			$(this).addClass('active');	  
			$('#tour2').show();	  				 
			return false;			
		});
		$(".tour3").click(function() {
			$('#itinerary, #dates, #price, #map, #tour1, #tour2').hide();
			$('.itinerary, .dates, .price, .map, .tour1, .tour2').removeClass('active');					   
			$(this).addClass('active');	  
			$('#tour3').show();	  				 
			return false;			
		});
		
		//----------------- Tab Script Ends ---------------------
		
		$("#showTools").click(function() {			  
			$('#widgetControllor').hide("slide", { direction: "down" }, "fast");
			$('#floatingWidget').show("slide", { direction: "down" }, "fast");
			return false;			
		});			
		$(".resetFont").click(function() {
			$('p').css('font-size', '16px');			  
			return false;			
		});
		$(".smallFont").click(function() {			
			$('p').css('font-size', '14px');
			return false;
		});	
		$(".largeFont").click(function() {			
			$('p').css('font-size', originalFontSize);
			return false;
		});		
		$(".changeImg li").mouseover(function() {										
			var index = $('.changeImg li').index(this);
			$('#holidayType img').addClass('hideimg').removeClass('showimg');
			$('#holidayType img:eq('+index+')').removeClass('hideimg').addClass('showimg');
			return false;			
		});		
		$(".changeMap a").hover(function() {										
			var index = $('.changeMap a').index(this);
			$('#mapWidget img').addClass('hidemap').removeClass('showmap');
			$('#mapWidget img:eq('+index+')').removeClass('hidemap').addClass('showmap');
			return false;			
			}, function(){  	
				$('#mapWidget img').addClass('hidemap').removeClass('showmap');
				$('#mapWidget img:eq(6)').removeClass('hidemap').addClass('showmap');		
		});  
		$("#pnlMenu").hover(function(){                  	
			}, function(){
				$('.dropdown').hide();
				$("a.mainMenu").removeClass("selected");
			}); 

		$("a.mainMenu").hover(function() {	
			$('.dropdown').hide();                        
			$("a.mainMenu").removeClass("selected");	
			var index = $('a.mainMenu').index(this);				
			if (index >=1 && index <=7) {                              
				$('.dropdown:eq('+(index-1)+')').show();	
				$('a.mainMenu:eq('+ index+')').addClass("selected");	
				$('.dropdown').hover(function() {  
				//Do nothing			
				}, function(){
                                        $('.dropdown').hide();
					$("a.mainMenu").removeClass("selected");										
				});                                
			}
		});
              
		
		$('#temp_country').change(function() {					   
			var country = $(this).val();
			//$('#temp_city').val().removeAttr('disabled');
			$cityList = $('#temp_city');
			if(country != '')
			{				
				$.ajax({
				type: 'get',
				async: false,
				//cache: false,
				url: 'includes/php/ch-country.php',
				data: 'country='+country+'&ac=country',
				beforeSend: function(){					
				},
				complete: function(){ 					
				},
				success: function(data) {					
				if(data)
					{
						$cityList.html(data).length;				
					}
					else
						$cityList.html('');
					}
				});
			}
		});
		
		$('.weatherhide').click(function() {
			$('#weatherChart').hide();
			$('#temp_country').val(-1);	
			$('#temp_city').html('');
			return false;			
		});
		
		$('#weatherinfo').click(function() {					   
			var country = $('#temp_country').val();			
			var cityList = $('#temp_city').val();
			$weatherChart = $('#weathertable');
			$('#weatherChart').show();
			if(cityList != '')
			{				
				$.ajax({
					type: 'get',
					async: false,
					//cache: false,
					url: 'includes/php/ch-country.php',
					data: 'country='+country+'&city='+cityList+'&ac=weather',
					beforeSend: function(){					
					},
					complete: function(){ 					
					},
					success: function(data) {									
					if(data)
					{
						$weatherChart.html(data);				
					}
					else
						$weatherChart.html('');
					}
				});
			}
		});

           $('#emailSubmit').click(function() { 
				var isOk = true;
			if($.trim($('#frmName').val()) == '')
			{
				alert('Please enter your full name.');
				var index = $('#frmName').focus();			
				isOk = false;
				return false;
			}
			
			if($.trim($('#frmEmail').val()) == '')
			{
				alert('Please enter your email id.');
				var index = $('#frmEmail').focus();			
				isOk = false;
				return false;
			}
			
			if(!CheckEmail($.trim($('#frmEmail').val())))
			{
				alert("Please enter a valid email id.");
				var index = $('#frmEmail').focus();			
				isOk = false;
				return false;
			}
			
			if($.trim($('#toName').val()) == '')
			{
				alert('Please enter name of your friend.');
				var index = $('#toName').focus();			
				isOk = false;
				return false;
			}
			
			if($.trim($('#toEmail').val()) == '')
			{
				alert('Please enter email of your friend.');
				var index = $('#toEmail').focus();			
				isOk = false;
				return false;
			}
			
			if(!CheckEmail($.trim($('#toEmail').val())))
			{
				alert("Please enter a valid email of your friend.");
				var index = $('#toEmail').focus();			
				isOk = false;
				return false;
			}
			
		if(isOk)
		{			                                 
			var frmName = $('#frmName').val();
			var frmEmail = $('#frmEmail').val();
			var toName = $('#toName').val();
			var toEmail = $('#toEmail').val();
			$dspmail = $('#dspmail');
			if(frmEmail != '' || toEmail != '' )
			{
				$.ajax({
					type: 'get',
					async: false,
					//cache: false,
					url: 'includes/php/ch-refermail.php',
					data: 'frmName='+frmName+'&frmEmail='+frmEmail+'&toName='+toName+'&toEmail='+toEmail+'&ac=refermail',
					beforeSend: function(){
						$('#emailSubmit').val('Please wait !!!');
					},
					complete: function(){
					},
					success: function(data) {
					if(data)
					{
						data = data.split("|");						
						alert(data[1]);
						$('#emailSubmit').val('Submit');						
						$(':input','#frmReffer')
						 .not(':button, :submit, :reset, :hidden')
						 .val('');
						$('#dspmail').hide("slide", { direction: "down" }, 500);				
						divShow = 0;		
					}
					else {
						//$dspmail.html('Sorry!!!');
					}
				}
			});
			}
		}
		});
		
		$('#brochureSubmit').click(function() {
			var isOk = true;
			if($.trim($('#broName1').val()) == '')
			{
				alert('Please enter your first name.');
				var index = $('#broName1').focus();			
				isOk = false;
				return false;
			}
			
			if($.trim($('#broName2').val()) == '')
			{
				alert('Please enter your last name.');
				var index = $('#broName2').focus();			
				isOk = false;
				return false;
			}
			if($.trim($('#broEmail').val()) == '')
			{
				alert('Please enter your email id.');
				var index = $('#broEmail').focus();			
				isOk = false;
				return false;
			}
			
			if(!CheckEmail($.trim($('#broEmail').val())))
			{
				alert("Please enter a valid email id.");
				var index = $('#broEmail').focus();			
				isOk = false;
				return false;
			}
			
			if($.trim($('#broCode').val()) == '')
			{
				alert('Please enter your Country code.');
				var index = $('#broCode').focus();			
				isOk = false;
				return false;
			}
			
			if(isNaN($('#broCode').val()))
			{
				alert('Please enter country code in numbers');
				var index = $('#broCode').focus();			
				isOk = false;
				return false;
			}
			
			if($.trim($('#broPhone').val()) == '')
			{
				alert('Please enter your phone no.');
				var index = $('#broPhone').focus();			
				isOk = false;
				return false;
			}
			
			if(isNaN($('#broPhone').val()))
			{
				alert('Please enter a valid phone no. in numbers');
				var index = $('#broPhone').focus();			
				isOk = false;
				return false;
			}
			
			if($.trim($('#broAddress1').val()) == '')
			{
				alert('Please enter your address.');
				var index = $('#broAddress1').focus();			
				isOk = false;
				return false;
			}
					
			if($.trim($('#broCity').val()) == '')
			{
				alert('Please enter your city.');
				var index = $('#broCity').focus();			
				isOk = false;
				return false;
			}
			
			if($.trim($('#broState').val()) == '')
			{
				alert('Please enter your residen state.');
				var index = $('#broState').focus();			
				isOk = false;
				return false;
			}
								
			if($.trim($('#broCountry').val()) == '-1')
			{
				alert('Please select your country');
				var index = $('#broCountry').focus();			
				isOk = false;
				return false;
			}
			
			if($.trim($('#broPin').val()) == '')
			{
				alert('Please enter pin code.');
				var index = $('#broPin').focus();			
				isOk = false;
				return false;
			}
			
		if(isOk)
		{			                 
			var frmName1 = $('#broName1').val();
			var frmName2 = $('#broName2').val();
			var frmEmail = $('#broEmail').val();
			var frmCode = $('#broCode').val();
			var frmPhone = $('#broPhone').val();
			var frmCity = $('#broCity').val();
			var frmState = $('#broState').val();
			var frmCountry = $('#broCountry').val();
			var frmAddress1 = $('#broAddress1').val();
			var frmAddress2 = $('#broAddress2').val();
			var frmPin = $('#broPin').val();
			$dspbrochure = $('#dspbrochure');
			if(frmName1 != '' || frmEmail != '' )
			{
				$.ajax({
					type: 'get',
					async: false,
					//cache: false,
					url: 'includes/php/ch-subscribe.php',
					data: 'frmName1='+frmName1+'&frmName2='+frmName2+'&frmEmail='+frmEmail+'&frmCode='+frmCode+'&frmPhone='+frmPhone+'&frmCity='+frmCity+'&frmState='+frmState+'&frmCountry='+frmCountry+'&frmAddress1='+frmAddress1+'&frmAddress2='+frmAddress2+'&frmPin='+frmPin+'&ac=subscribe',
					beforeSend: function(){
						$('#brochureSubmit').val('Please wait !!!');
					},
					complete: function(){
					},
					success: function(data) {
					if(data)
					{
						data = data.split("|");						
						alert(data[1]);
						$('#brochureSubmit').val('Submit');						
						$(':input','#frmBrochure')
						 .not(':button, :submit, :reset, :hidden')
						 .val('');
						$('#dspbrochure').hide("slide", { direction: "down" }, 500);				
						divShow2 = 0;		
					}
					else {
						//$dspmail.html('Sorry!!!');
					}
				}
			});
			}
		}
		});

            $('#newsSubmit').click(function() {
				var isOk = true;
			if($.trim($('#newsfrmName').val()) == '')
			{
				alert('Please enter your full name.');
				var index = $('#newsfrmName').focus();			
				isOk = false;
				return false;
			}
			
			if($.trim($('#newsfrmEmail').val()) == '')
			{
				alert('Please enter your email id.');
				var index = $('#newsfrmEmail').focus();			
				isOk = false;
				return false;
			}
			
			if(!CheckEmail($.trim($('#newsfrmEmail').val())))
			{
				alert("Please enter a valid email id.");
				var index = $('#newsfrmEmail').focus();			
				isOk = false;
				return false;
			}
			
		if(isOk)
		{			                 
			var frmName = $('#newsfrmName').val();
			var frmEmail = $('#newsfrmEmail').val();
			$dspmail = $('#dspnews');
			if(frmEmail != '' )
			{
				$.ajax({
					type: 'get',
					async: false,
					//cache: false,
					url: 'includes/php/ch-newsmail.php',
					data: 'frmName='+frmName+'&frmEmail='+frmEmail+'&ac=newsmail',
					beforeSend: function(){
						$('#newsSubmit').val('Please wait !!!');
					},
					complete: function(){
					},
					success: function(data) {
					if(data)
					{
						data = data.split("|");
						alert(data[1]);
						$('#newsSubmit').val('Submit');
						$(':input','#frmNews')
						 .not(':button, :submit, :reset, :hidden')
						 .val('');
						$('#dspnews').hide("slide", { direction: "down" }, 500);
						divShow1 = 0;
					}
					else {
						//$dspmail.html('Sorry!!!');
					}
				}
			});
			}
		}
		});
			
		$('#selDestination').change(function() {					   
			GetTours();		
		});
		
		$('#txtDays').blur(function() {			
			GetTours();			
		});		
		
		function GetTours() {						
			var country = $('#selDestination').val();			
			$cityList = $('#selTour');
			var days = $('#txtDays').val()
			if(country != '')
			{				
				$.ajax({
				type: 'get',
				async: false,
				//cache: false,
				url: 'includes/php/ch-country.php',
				data: 'country='+country+'&days='+days+'&ac=tours',
				beforeSend: function(){					
				},
				complete: function(){ 					
				},
				success: function(data) {					
					if(data)
					{
						$cityList.html(data).length;				
					}
					else
						$cityList.html('');
					}
				});
			}
			else
				{$cityList.html('');}
		}
		$("#chkDates").click(function(){
		  var chkVal = $("#chkDates").is(':checked');
		  if (chkVal == true) {
			  $("#chkStaus").val("All");
		  }
		  else
			  { $("#chkStaus").val("");}              
		 });
		 
		 $("#homeForm").submit(function() {
		   var chkVal = $("#chkDates").is(':checked');
		  if ($("#selTour").val() == "") {
			  alert("Please select tour");
			  return false;
		  }             
		  if ($("#txtFrom").val() == "" && chkVal == false) {
			  alert("Please enter from date or check all dates");
			  return false;
		  }
		});
	//----------------------------------------------------------------------------------------------------------------	
	});
	
	var arrDestinations = new Array("Africa","Alaska","America","Australia","Baltics","Bolivia","Budapest","Canada","Chile","China","Cyprus","EU Triangle","Egypt","Europe","Holland","Hungary","India","Ireland","Italy","Jordan","Kenya","London","Middle East","Oman","Paris","Peru","Poland","Scotland","Slovenia","South Africa","Spain","Sri Lanka","Switzerland","Tanzania","Tunis","Turkey");
	var arrCountry = new Array("Afghanistan","Algeria","Argentina","Armenia","Aruba","Australia","Austria","Bahamas","Barbados","Belgium","Bermuda","Brazil","Cambodia","Canada","Chile","China","Colombia","Denmark","Ecuador","Egypt","France","Georgia","Germany","Greece","India","Indonesia","Iran","Iraq","Ireland","Israel","Italy","Jamaica","Japan","Jordan","Kenya","Korea","Luxembourg","Malaysia","Maldives","Mauritius","Mexico","Morocco","Mozambique","Myanmar","Nepal","Netherlands","Oman","Paraguay","Peru","Philippines","Poland","Portugal","Russia","Singapore","South_Africa","Spain","Sri_Lanka","Switzerland","Thailand","Tunisia","Turkey","Turkmenistan","Turks_And_Caicos_Is.","Uganda","Ukraine","Un.States_Of_America","United_Arab_Emirates","United_Kingdom","Venezuela");
        var arrCurrency = new Array("","","USD","United States Dollars","EUR","Euro","GBP","United Kingdom Pounds","JPY","Japan Yen","AFN","Afghanistan Afghanis","ALL","Albania Leke","DZD","Algeria Dinars","ARS","Argentina Pesos","AUD","Australia Dollars","BSD","Bahamas Dollars ","BHD","Bahrain Dinars","BDT","Bangladesh Taka","BBD","Barbados Dollars","BMD","Bermuda Dollars","BRL","Brazil Reais","BGN","Bulgaria Leva","CAD","Canada Dollars","XOF","CFA Francs BCEAO CFAF","XAF","CFA Francs BEAC CFAF","XPF","CFP Francs","CLP","Chile Pesos","CNY","China Yuan Renminbi","CRC","Costa Rica Colones","HRK","Croatia Kuna","CYP","Cyprus Pounds","CZK","Czech Republic Koruny","DKK","Denmark Kroner","DOP","Dominican Republic Pesos","XCD","East Caribbean Dollars","EGP","Egypt Pounds","EEK","Estonia Krooni","FJD","Fiji Dollars","HKD","Hong Kong Dollars","HUF","Hungary Forint","ISK","Iceland Kronur","XDR","IMF Special Drawing Rights ","INR","India Rupees","ILS","Israel New Shekels","JMD","Jamaica Dollars","JOD","Jordan Dinars","KZT","Kazakhstan Tenge","KES","Kenya Shillings","KWD","Kuwait Dinars","MYR","Malaysia Ringgits","MTL","Malta Liri","MUR","Mauritius Rupees","MXN","Mexico Pesos","MAD","Morocco Dirhams","NZD","New Zealand Dollars","NGN","Nigeria Nairas","NOK","Norway Kroner","OMR","Oman Rials ","PKR","Pakistan Rupees","XPD","Palladium Ounces ","PEN","Peru Nuevos Soles","PHP","Philippines Pesos","PLN","Poland Zlotych","QAR","Qatar Riyals","RON","Romania New Lei","RUB","Russia Rubles","SAR","Saudi Arabia Riyals","XAG","Silver Ounces ","SGD","Singapore Dollars","ZAR","South Africa Rand","LKR","Sri Lanka Rupees","SDG","Sudan Pounds","SEK","Sweden Kronor","CHF","Switzerland Francs","TWD","Taiwan New Dollars","THB","Thailand Baht","TTD","Trinidad and Tobago Dollars","TND","Tunisia Dinars","TRY","Turkey Lira","AED","United Arab Emirates Dirhams","VEF","Venezuela Bolivares Fuertes");
	function FillCountry()
	{
		for(i=0; i<arrCountry.length; i++)
		{
			document.getElementById("temp_country").options[i+1] = new Option(arrCountry[i],arrCountry[i]);
		}
		document.getElementById("temp_country").options[0] = new Option("Select Country","",true);
		document.getElementById("temp_country").selectedIndex = 0;
	}
        function FillCountry1()
	{
		for(i=0; i<arrCountry.length; i++)
		{
			document.getElementById("Country").options[i+1] = new Option(arrCountry[i],arrCountry[i]);
		}
		document.getElementById("Country").options[0] = new Option("Select Country","",true);
		document.getElementById("Country").selectedIndex = 0;
	}
	
	function FillCountry2()
	{
		for(i=0; i<arrCountry.length; i++)
		{
			document.getElementById("broCountry").options[i+1] = new Option(arrCountry[i],arrCountry[i]);
		}
		document.getElementById("broCountry").options[0] = new Option("Your Country","",true);
		document.getElementById("broCountry").selectedIndex = 0;
	}
	
	function FillDestinations()
	{
		for(i=1; i<arrDestinations.length; i++)
		{
			document.getElementById("selDestination").options[i+1] = new Option(arrDestinations[i],arrDestinations[i]);
		}
		document.getElementById("selDestination").options[0] = new Option("Select Destination","",true);
                document.getElementById("selDestination").options[1] = new Option("All Destination","All");
		document.getElementById("selDestination").selectedIndex = 0;
	}

        function gp_currencySymbols()
	{
                var n = 0;
		for(i=1; i<arrCurrency.length; i=i+2)
		{
			document.getElementById("gp_from").options[n] = new Option(arrCurrency[i],arrCurrency[i-1]);
                        document.getElementById("gp_to").options[n] = new Option(arrCurrency[i],arrCurrency[i-1]);
                        n++;
		}
		document.getElementById("gp_from").options[0] = new Option("Select Country","",true);
		document.getElementById("gp_from").selectedIndex = 0;                
		document.getElementById("gp_to").options[0] = new Option("Select Country","",true);
		document.getElementById("gp_to").selectedIndex = 0;
                
	}
        /*
	function gp_currencySymbols() {
	$.getJSON("http://www.geoplugin.net/currency_symbols.gp?format=json&jsoncallback=?",
		function(data){
			var currencyCode = geoplugin_currencyCode();
			var fromCurr = '';
			var toCurr = '';

			$.each(data, function(i,item){
				if ( currencyCode == i ) {
					fromCurr = fromCurr + "<option value='"+i+"' selected>"+item.name+" "+(item.symbol?item.symbol:'')+"</option>";
				} else {
					fromCurr = fromCurr + "<option value='"+i+"'>"+item.name+" "+(item.symbol?item.symbol:'')+"</option>";
				}
			});          
			$.each(data, function(i,item){
				if ( currencyCode == 'USD' && i == 'EUR' ) {
					toCurr = toCurr + "<option value='"+i+"' selected>"+item.name+" "+(item.symbol?item.symbol:'')+"</option>";
				} else {
					toCurr = toCurr + "<option value='"+i+"'>"+item.name+" "+(item.symbol?item.symbol:'')+"</option>"; //{condition)? iftrue : iffalse
				}
			});
			$(fromCurr).appendTo("#gp_from");
			$(toCurr).appendTo("#gp_to");
		});
	};*/
        
	function gp_convertIt() {
		if (!document.getElementById('gp_amount').value){
			return false;
		} else {
		var gp_from = document.getElementById('gp_from').value;
		var gp_to = document.getElementById('gp_to').value;
		var gp_amount = document.getElementById('gp_amount').value;
		$.getJSON( "http://www.geoplugin.net/currency_converter.gp?jsoncallback=?", { from:gp_from, to:gp_to, amount:gp_amount }, 
			function(output){
				$("#gp_converted").html("<div style='padding:0'><strong>"+output.from.symbol+output.from.amount+" = "+output.to.symbol+output.to.amount+"</strong></div>");
			});
		}
	};	
	
	/*function mailpage()
{
  mail_str = "mailto:?subject= Very Interesting Website !!";
  mail_str += "&body= I found this page quite interesing";
  mail_str += ". I thoughtYou should check this out at, " + location.href; 
  location.href = mail_str;
}
*/
function CheckEmail(src)
{
	var emailReg = "^([0-9a-zA-Z]+[-._+&])*[0-9a-zA-Z]+@([-0-9a-zA-Z]+[.])+[a-zA-Z]{2,6}$";
	var regex = new RegExp(emailReg);
	return regex.test(src);
}


