Jump to content
Fórum Script Brasil
  • 0

Chamar Função Pelo Radion Button


X-MAN
 Share

Question

ola pessoal, queria que ao clicar no radion button chamasse a função "teste", mas essa tristeza de codigo não funciona... pk??? :wacko:

<form id="form1" name="form1" method="post" action="">
  <label>
  <input name="radiobutton" type="radio" value="radiobutton" onclick="<%teste(1)%>"/>
  </label>
</form>
<%
function teste(numero)
if numero = "0" then
response.Write("nada")
else
response.Write("teste efetuado")
end if

end function
%>

Agradecia a ajuda!!

Link to comment
Share on other sites

2 answers to this question

Recommended Posts

  • 0

X-MAN, assim vai funcionar,

da uma olhada ai,

<script Language="JavaScript">
function teste(numero){
if (numero == "0")
alert('nada');
else
alert('teste efetuado')

}

</Script>

<form id="form1" name="form1" method="post" action="">
  <label>
  <input name="radiobutton" type="radio" value="radiobutton" onclick="teste('<%=teste(1)%>');">Click
  </label>
</form>

falou

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share



  • Forum Statistics

    • Total Topics
      151k
    • Total Posts
      649k
×
×
  • Create New...