Ir para conteúdo
Fórum Script Brasil
  • 0

preciso de um button que ative outros


Guest --Jean --

Pergunta

Olá pessoal, estou precisando de uma grande ajuda, eu já tentei mais não consegui sozinho.

acontece o seguinte, pra facilitar minha vida em uma transação que exige repetição do mesmo passo várias vezes eu comecei esse script que já esta me adianto bastante, estou lucrando no tempo, mais mesmo assim ainda queria otimizar ainda mais o sistema.

vejam a imagem da tela: http://img518.imageshack.us/my.php?image=telascripta3ao0.jpg

então, eu tenho que colocar os cinco codigos de verificação manualmente mesmo, mais tenho que apertar os 5 butões "enviar", preciso de um script que ao clicar um unico butão este acione os demais com um intervalo de tempo de uns 30seg, deu pra entenderem +/- o que preciso???

aguardo por algum auxilio de quem domina o assunto....

Link para o comentário
Compartilhar em outros sites

6 respostass a esta questão

Posts Recomendados

  • 0

Olá pessoal, estou precisando de uma grande ajuda, eu já tentei mais não consegui sozinho.

acontece o seguinte, pra facilitar minha vida em uma transação que exige repetição do mesmo passo várias vezes eu comecei esse script que já esta me adianto bastante, estou lucrando no tempo, mais mesmo assim ainda queria otimizar ainda mais o sistema.

vejam a imagem da tela: http://img518.imageshack.us/my.php?image=telascripta3ao0.jpg

então, eu tenho que colocar os cinco codigos de verificação manualmente mesmo, mais tenho que apertar os 5 butões "enviar", preciso de um script que ao clicar um unico butão este acione os demais com um intervalo de tempo de uns 30seg, deu pra entenderem +/- o que preciso???

aguardo por algum auxilio de quem domina o assunto....

Link para o comentário
Compartilhar em outros sites

  • 0
posta seu código ae, fica mais fácil ajudar

o código da página é:

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<!-- Script em desenvolvimento para facilitar os saques no A3 -->
<html>
<head>

  <meta content="text/html; charset=ISO-8859-1" http-equiv="content-type">
  <title>A3</title>


  <link href="http://a3union.com/css.css" rel="stylesheet" type="text/css">
  
  <meta HTTP-EQUIV="Refresh" CONTENT="180"; URL ="retira.html">

  <base target="principal">

</head>


<body style="color: rgb(0, 0, 0);" alink="#ee0000" link="#0000ee" vlink="#551a8b">

<div style="text-align: center;">
&lt;script language="JavaScript">
<!--
function FP_swapImg() 
{//v1.0
var doc=document,args=arguments,elm,n; doc.$imgSwaps=new Array(); for(n=2; n<args.length;
n+=2) { elm=FP_getObjectByID(args[n]); if(elm) { doc.$imgSwaps[doc.$imgSwaps.length]=elm;
elm.$src=elm.src; elm.src=args[n+1]; } }
}
function FP_preloadImgs() 
{//v1.0
var d=document,a=arguments; if(!d.FP_imgs) d.FP_imgs=new Array();
for(var i=0; i<a.length; i++) { d.FP_imgs[i]=new Image; d.FP_imgs[i].src=a[i]; }
}
function FP_getObjectByID(id,o) 
{//v1.0
var c,el,els,f,m,n; if(!o)o=document; if(o.getElementById) el=o.getElementById(id);
else if(o.layers) c=o.layers; else if(o.all) el=o.all[id]; if(el) return el;
if(o.id==id || o.name==id) return o; if(o.childNodes) c=o.childNodes; if©
for(n=0; n<c.length; n++) { el=FP_getObjectByID(id,c[n]); if(el) return el; }
f=o.forms; if(f) for(n=0; n<f.length; n++) { els=f[n].elements;
for(m=0; m<els.length; m++){ el=FP_getObjectByID(id,els[n]); if(el) return el; } }
return null;
}
function FP_swapImgRestore() 
{//v1.0
var doc=document,i; if(doc.$imgSwaps) { for(i=0;i<doc.$imgSwaps.length;i++) {
var elm=doc.$imgSwaps[i]; if(elm) { elm.src=elm.$src; elm.$src=null; } } doc.$imgSwaps=null; }
}

// -->
</script>


<font color="#808080" size="3"><a name="_A3:_Sistema_Retirada_de_e-Gold_"></a>
<span style="font-weight: bold; color: rgb(51, 51, 255);"># A3:
Sistema Retirada de e-Gold #</span></font></div>

<div style="text-align: center;"><font size="1">O
Sistema não processa retirada instantanea no seguinte
intervalo de horário: 14:00
- 23:00 GMT. <br>

</font></div>

<blockquote>
  <form style="background-color: rgb(204, 255, 255);" name="shoppingcart" 
              action="http://a3union.com/cgi-bin/main.pl" method="post"> 
  <p align="center"> 
  <font size="2"> 
  
  <input name="s" value="10" type="hidden">
  </font> <font size="2">

  
  <input name="act" value="withdraw" type="hidden"> <font size="2"><br>


    <b>
    <span style="color: rgb(204, 0, 0);">Valor para retirada:  </span>    
  </b><input name="amo" value="5.15" class="in" type="text" size="11">  <br>

    <br>

    <b style="color: rgb(204, 0, 0);">Código de Segurança:</b> <span style="color: rgb(204, 0, 0)"> </span>
  <input name="TURING" size="11" style="color: #0000EE; font-weight: bold; border: 1px solid rgb(128, 128, 128)" maxlength="5" type="text">
         <img src="http://a3union.com/cgi-bin/turing2.pl?s=10">                
  <input type="submit" value="Enviar" name="submit1" _blank>
<br>

    <br>

    </font></font> </form>

</blockquote>



<blockquote>
  <form style="background-color: rgb(204, 255, 255);" name="shoppingcart" 
              action="http://a3union.com/cgi-bin/main.pl" method="post"> 
  <font size="2"> 
  
  <input name="s" value="1697656536" type="hidden">
  </font> <font size="2">

  
  <input name="act" value="withdraw" type="hidden"> <font size="2"><br>


    <b>
    <span style="color: rgb(204, 0, 0);">Valor para retirada:  </span>    
  </b><input name="amo" value="5.15" class="in" type="text" size="11">  <br>

    <br>

    <b style="color: rgb(204, 0, 0);">Código de Segurança:</b> <span style="color: rgb(204, 0, 0)"> </span>
  <input name="TURING" size="11" style="color: #0000EE; font-weight: bold; border: 1px solid rgb(128, 128, 128)" maxlength="5" type="text">
         <img src="http://a3union.com/cgi-bin/turing2.pl?s=1697656536">                
  <input type="submit" value="Enviar" name="submit2" _blank>
<br>

    <br>

    </font></font> </form>

</blockquote>


<blockquote>
  <form style="background-color: rgb(204, 255, 255);" name="shoppingcart" 
              action="http://a3union.com/cgi-bin/main.pl" method="post"> 
  <font size="2"> 
  
  <input name="s" value="1697656539" type="hidden">
  </font> <font size="2">
  
  <input name="act" value="withdraw" type="hidden"> <font size="2"><br>


    <b>
    <span style="color: rgb(204, 0, 0);">Valor para retirada:  </span>    
  </b><input name="amo" value="5.15" class="in" type="text" size="11">  <br>

    <br>

    <b style="color: rgb(204, 0, 0);">Código de Segurança:</b> <span style="color: rgb(204, 0, 0)"> </span>

  <input name="TURING" size="11" style="color: #0000EE; font-weight: bold; border: 1px solid rgb(128, 128, 128)" maxlength="5" type="text">
         <img src="http://a3union.com/cgi-bin/turing2.pl?s=1697656539">                
  <input type="submit" value="Enviar" name="submit3" _blank>
<br>

    <br>

    </font></font> </form>

</blockquote>

<blockquote>
  <form style="background-color: rgb(204, 255, 255);" name="shoppingcart" 
              action="http://a3union.com/cgi-bin/main.pl" method="post"> 
  <font size="2"> 
  
  <input name="s" value="1697656545" type="hidden">
  </font> <font size="2">
  
  <input name="act" value="withdraw" type="hidden"> <font size="2"><br>


    <b>
    <span style="color: rgb(204, 0, 0);">Valor para retirada:  </span>    

  </b><input name="amo" value="5.15" class="in" type="text" size="11">  <br>

    <br>

    <b style="color: rgb(204, 0, 0);">Código de Segurança:</b> <span style="color: rgb(204, 0, 0)"> </span>
  <input name="TURING" size="11" style="color: #0000EE; font-weight: bold; border: 1px solid rgb(128, 128, 128)" maxlength="5" type="text">
         <img src="http://a3union.com/cgi-bin/turing2.pl?s=1697656545">                

  <input type="submit" value="Enviar" name="submit4" _blank>
<br>

    <br>

    </font></font> </form>

</blockquote>

<blockquote>
  <form style="background-color: rgb(204, 255, 255);" name="shoppingcart" 
              action="http://a3union.com/cgi-bin/main.pl" method="post"> 
  <font size="2"> 
  
  <input name="s" value="1097656539" type="hidden">

  </font> <font size="2">
  
  <input name="act" value="withdraw" type="hidden"> <font size="2"><br>


    <b>
    <span style="color: rgb(204, 0, 0);">Valor para retirada:  </span>    
  </b><input name="amo" value="5.15" class="in" type="text" size="11">  <br>

    <br>

    <b style="color: rgb(204, 0, 0);">Código de Segurança:</b> <span style="color: rgb(204, 0, 0)"> </span>
  <input name="TURING" size="11" style="color: #0000EE; font-weight: bold; border: 1px solid rgb(128, 128, 128)" maxlength="5" type="text">
         <img src="http://a3union.com/cgi-bin/turing2.pl?s=1097656539">                
  <input type="submit" value="Enviar" name="submit5" _blank>
<br>

    <br>

    </font></font> </form>

</blockquote>


</body>
</html>

Link para o comentário
Compartilhar em outros sites

  • 0

Dê nomes diferentes para cada form

ai cria uma função para enviar os forms (ex.: document.form1.submit();)

http://www.w3schools.com/htmldom/dom_obj_form.asp

e você pode usar um array e um for para ri enviando os forms. para colocar intervalo de 30 segundos utilize o setTimeout();

http://www.w3schools.com/htmldom/met_win_settimeout.asp

Link para o comentário
Compartilhar em outros sites

  • 0
Dê nomes diferentes para cada form

ai cria uma função para enviar os forms (ex.: document.form1.submit();)

http://www.w3schools.com/htmldom/dom_obj_form.asp

e você pode usar um array e um for para ri enviando os forms. para colocar intervalo de 30 segundos utilize o setTimeout();

http://www.w3schools.com/htmldom/met_win_settimeout.asp

Valeu, muito obrigado pela dica

vou refazer toda estrutura do codigo e logo posto o resultado aqui

Link para o comentário
Compartilhar em outros sites

Participe da discussão

Você pode postar agora e se registrar depois. Se você já tem uma conta, acesse agora para postar com sua conta.

Visitante
Responder esta pergunta...

×   Você colou conteúdo com formatação.   Remover formatação

  Apenas 75 emoticons são permitidos.

×   Seu link foi incorporado automaticamente.   Exibir como um link em vez disso

×   Seu conteúdo anterior foi restaurado.   Limpar Editor

×   Você não pode colar imagens diretamente. Carregar ou inserir imagens do URL.



  • Estatísticas dos Fóruns

    • Tópicos
      152,1k
    • Posts
      651,8k
×
×
  • Criar Novo...