// JavaScript Document
function multimidia(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}

function cadastre(url)
{
window.open(url,'cadastro','width=390,height=380,scrollbars=no');
}

function videos(url)
{
window.open(url,'videos','width=650,height=430,scrollbars=no resize=no left=150, top=100');
}

function mandaFoto(url)
{
window.open(url,'mandaFoto','width=400,height=350,scrollbars=no');
}

function abreRadio(url) {
	window.open(url,'radio','width=253,border=no,height=113,scrollbars=no,top=50,left=200');
}

// funcao para controlar o envio de foto pelo corrigir

function salvaFoto(){
var nomeFoto = String;
       if (document.upload.foto.value != null){
          nomeFoto  = document.upload.foto.value;
          }

window.open('<%=site%>/central1.1/corrigir/corrige.php?foto='+nomeFoto+'','foto','resizable=yes,width=350,height=400,scrollbars=no');
}



function popUpPoll(){
var oVoto=0
var idPergunta = 0
//For each radio button if it is checked get the value and quit.
   for (var i = 0; i < document.enqueteForm.poll.length; i++){
       if (document.enqueteForm.poll[i].checked){
          oVoto = document.enqueteForm.poll[i].value;
		  idPergunta = document.enqueteForm.idPergunta.value;
          }
        }
   //alert(oVoto)
  if (oVoto!=0){ 
  	window.open('<%=site2%>/enquete/poll.asp?action=vote&idPergunta='+idPergunta+'&poll='+oVoto+'','poll'+idPergunta+'','resizable=yes,width=350,height=450,scrollbars=no');
		}
   }

function popUpApuracao(){
var idPergunta2 = 0;
       if (document.resultados.idPergunta2.value != null){
          idPergunta2  = document.resultados.idPergunta2.value;
          }

window.open('<%=site2%>/enquete/resultados.asp?idPergunta='+idPergunta2+'','resultados','resizable=yes,width=350,height=400,scrollbars=no');
}

function popUpAnteriores(){
window.open('<%=site2%>/enquete/archive.asp','anteriores','resizable=yes,width=250,height=400,scrollbars=no');
}
