
	function sendemail() {
		if (document.forms['email'])
			document.forms['email'].submit();
	}

	function listingpreviousstep()
	{
		if (document.forms['addlistingform'])
		{
			if (document.forms['addlistingform'].previousstep)
			{
				document.forms['addlistingform'].previousstep.value = 'previousstep';
				document.forms['addlistingform'].submit();
			}
		}
	}

	function listingnextstep()
	{
		if (document.forms['addlistingform'])
			document.forms['addlistingform'].submit();
	}

	function listinglogin()
	{
		if (document.forms['addlistingform'])
			document.forms['addlistingform'].submit();
	}

	function reservationnextstep()
	{
		if (document.forms['reservationform'])
			document.forms['reservationform'].submit();
	}

	function openwebsite() {
		if (document.forms['addlistingform'])
			var pageurl = document.forms['addlistingform'].website.value;
			if ((pageurl.length != 0) && (pageurl.toLowerCase() != "http://"))
				var win = window.open(pageurl, '_blank');
	}

	function tipsShortDescription() {
		var pageurl = '/tips_short_description.htm';
		var pagetitle = 'AvvieAddListingTips';
		var width = 450;
		var height = 200;
		var myleft = (screen.width) ? (screen.width - width) / 2 : 100;
		var mytop = (screen.height) ? (screen.height - height) / 2 : 100;
		settings = "width=" + width + ",height=" + height + ",top=" + mytop + ",left=" + myleft + ",scrollbars=yes,location=no,directories=no,status=no,menubar=no,toolbar=no,resizable=yes";
		var win = window.open ( pageurl, pagetitle, settings );
		win.focus();
	}
	
	function tipsShortDescriptionCalendar() {
		var pageurl = '/tips_short_description_calendar.htm';
		var pagetitle = 'AvvieAddListingTips';
		var width = 450;
		var height = 200;
		var myleft = (screen.width) ? (screen.width - width) / 2 : 100;
		var mytop = (screen.height) ? (screen.height - height) / 2 : 100;
		settings = "width=" + width + ",height=" + height + ",top=" + mytop + ",left=" + myleft + ",scrollbars=yes,location=no,directories=no,status=no,menubar=no,toolbar=no,resizable=yes";
		var win = window.open ( pageurl, pagetitle, settings );
		win.focus();
	}

	function tipsLongDescription() {
		var pageurl = '/tips_long_description.htm';
		var pagetitle = 'AvvieAddListingTips';
		var width = 450;
		var height = 200;
		var myleft = (screen.width) ? (screen.width - width) / 2 : 100;
		var mytop = (screen.height) ? (screen.height - height) / 2 : 100;
		settings = "width=" + width + ",height=" + height + ",top=" + mytop + ",left=" + myleft + ",scrollbars=yes,location=no,directories=no,status=no,menubar=no,toolbar=no,resizable=yes";
		var win = window.open ( pageurl, pagetitle, settings );
		win.focus();
	}

	function tipsKeywords() {
		var pageurl = '/tips_keywords.htm';
		var pagetitle = 'AvvieAddListingTips';
		var width = 450;
		var height = 200;
		var myleft = (screen.width) ? (screen.width - width) / 2 : 100;
		var mytop = (screen.height) ? (screen.height - height) / 2 : 100;
		settings = "width=" + width + ",height=" + height + ",top=" + mytop + ",left=" + myleft + ",scrollbars=yes,location=no,directories=no,status=no,menubar=no,toolbar=no,resizable=yes";
		var win = window.open ( pageurl, pagetitle, settings );
		win.focus();
	}

	function processlisting(subscr) {
		if (document.forms['paypalpayment'])
		    document.forms['paypalpayment'].subscription.value = subscr;
			document.forms['paypalpayment'].submit();
	}


	function sendemail() {
		if (document.forms['email'])
			document.forms['email'].submit();
	}
	
	function clearsearch(whatField) {
	    if (whatField == 1) {
	        document.getElementById("search1").value = '';
	        document.getElementById("search1").style.color = '#000000';
	    }
	    else if (whatField == 2) {
	    	document.getElementById("search2").value = '';
	        document.getElementById("search2").style.color = '#000000';
	    }
	}
