
//anket start----------------------------------------------------
function validatePoll(objForm,ChoiceCount,pollID)
{
selectedChoice =-1;
var PollForm = document.getElementById(objForm);

for (i=0;i<ChoiceCount;i++) 
{
	if (PollForm.choice[i].checked) {
		selectedChoice=i;
		break;
	}
}

openstr= pollHref + "?pid=" + pollID;

if (selectedChoice!=-1) 
{
	openstr = openstr + '&choice=' + PollForm.choice[selectedChoice].value;
}

window.open(openstr,'pollPopup','left=100,top=100,toolbar=no,location=no,menubar=no,status=no,directories=no,scrollbars=yes,resizable=yes,width=600,height=350');
}

function pollResult(pollID) {

window.open(''+ pollHref +'?pid='+ pollID +'','anket','left=100,top=100,toolbar=no,location=no,menubar=no,status=no,directories=no,scrollbars=yes,resizable=yes,width=600,height=350');
}

function popupContact(url)
{
window.open(url,'Contact','left=100,top=100,toolbar=no,location=no,menubar=no,status=no,directories=no,scrollbars=yes,resizable=no,width=600,height=550');
}

function validate()
{
emailReg = "^[\\w-_\.]*[\\w-_\.]\@[\\w]+[\\w-_\.]+[.][\\w-_\.]+[a-zA-Z]$"
var regex = new RegExp(emailReg);


		if (document.uyelik.name.value=="")
			{
			alert("Lütfen adınızı girin.");
			return;
			}

		if (document.uyelik.email.value=="")
			{
			alert("Lütfen e-posta adresinizi girin.");
			return;
			}
			
		
		if (! (regex.test(document.uyelik.email.value)))
			{
			alert ("Lütfen e-posta adresinizi düzeltin !");
			return;
			}

	document.uyelik.submit();
}



//anket end----------------------------------------------------

