
Proteu
Membros-
Total de itens
38 -
Registro em
-
Última visita
Tudo que Proteu postou
-
(Resolvido) Evento on click não chama função
pergunta respondeu ao Proteu de Proteu em Ajax, JavaScript, XML, DOM
Vou chamar padre Quevedo pra ver meu sistema.... Quando respodi havia dado tudo certo e agora não aastr mais no banco.... a adição da document.form1.submit(); (que eu disse não precisar anteriormente) resolve o problema... retirei também "!" que estava antes do confirm... Segue corrigido <script language="JavaScript"> function valida_dados(){ if (form1.nmcurso.value==""){ alert("Favor Preencher o campo Curso."); document.form1.nmcurso.focus(); return false; } if(confirm("Você deseja mesmo cadastrar esta cidade?")){ document.form1.submit(); } } </script> -
(Resolvido) Evento on click não chama função
pergunta respondeu ao Proteu de Proteu em Ajax, JavaScript, XML, DOM
Bom dia companheiros, Jonathan--> não era exibido nenhum erro, a função só não era chamada...vou fazer uma pesquisa pra saber as vantagem de usar o que você disse e vou corrigir os demais códigos onde utulizei a mesma sintaxe... vlw pelas dicas.... :) Danilo--> deu certinho...agora chama a função. E pra mim está tudo ok (o botão cancelar apenas fecha o confirm box) <script language="JavaScript"> function valida_dados(){ if (form1.campo.value==""){//campo e o nome do input text... alert("Favor Preencher o campo Curso."); document.form1.campo.focus(); return false; }else{//aki o else que falei if (confirm("Você deseja mesmo cadastrar esta cidade?")) { return false; } } } </script> Não preciso de document.form1.submit(); pois tenho uma função fora deste JS que já faz o submit.... VlW GALERA! OBRIGADO PELA ATENÇÃO... -
Salvar dados de um formulário.
pergunta respondeu ao MegaRevolt de Proteu em Ajax, JavaScript, XML, DOM
verifica se os valores dos dois campos são iguais usando um JS , evento onclick... if (nomeform.senha.value==nomeform.confirma_senha.value){ alert("As senhas não confrem."); return false; } -
Boa tarde pessoal, to com uma duvida banal aki... Gostaria de chamar uma função depois de clicar no botão OK...porém não stou conseguindo.... segue o código para análise.... <script language="JavaScript"> function valida_dados(nmcurso){ if (nomeform.nmcurso.value==""){ alert("Favor Preencher o campo Curso."); document.form1.nmcurso.focus(); return false; } if (!confirm("Você deseja mesmo cadastrar esta cidade?")) { return false } } </script> . . . <form name="form1" method="post" action="curso2.php"> . . . <input type="submit" name="submit" value="cadastrar" onClick="valida_dados(this)"> <input type="submit2" name="submit" value="limpar" . . . Desculpe pela ignorância, mas sou iniciante em JS
-
Preciso código: Ao passar imagem, aparecer descrição num balão
pergunta respondeu ao Chriistiian de Proteu em Ajax, JavaScript, XML, DOM
<img src=imagem alt="texteo que voce quer exibir"> -
Calendario não é exibido completamente
pergunta respondeu ao Proteu de Proteu em Ajax, JavaScript, XML, DOM
Já testei só o código do calendário fora da minha página e deu certo....o que estou fazendo de errado? -
(Resolvido) problema com confirmação de cadastro
pergunta respondeu ao Proteu de Proteu em Ajax, JavaScript, XML, DOM
Obrigado pela paciência e atenção.... -
(Resolvido) problema com confirmação de cadastro
pergunta respondeu ao Proteu de Proteu em Ajax, JavaScript, XML, DOM
Assim? <form name="form1" method="post" action="cidade2.php" onSubmit="return valida_dados(this)"> <script language="JavaScript"> function valida_dados(nomeform){ if (nomeform.nmcidade.value==""){ alert("Favor Preencher o campo Cidade."); document.form1.nmcidade.focus(); return false; } if (confirm("Você deseja mesmo cadastrar está cidade?")) { location.href="cidade.php";} if (!confirm("Você deseja mesmo cadastrar está cidade?")) { return false } else { return true; } } </script> Não deu muito certo nuam....exibe o confim box dua vezes... Descupe a ignorância , mas sou iniciante em PHP... -
(Resolvido) problema com confirmação de cadastro
uma questão postou Proteu Ajax, JavaScript, XML, DOM
Olá, estou com problemas para usar um confirm box para confirmar uma exclusão....tanto clicando no botão "OK" quanto no "Cancelar" o sistema está cadastrando.... sei que está faltando um parametro ou coisa assim para que quando for pressionado o botão cancelar este somente feche o confirm box.... segue código para análise: <form name="form1" method="post" action="cidade2.php" onSubmit="return valida_dados(this)"> <script language="JavaScript"> function valida_dados(nomeform){ if (nomeform.nmcidade.value==""){ alert("Favor Preencher o campo Cidade."); document.form1.nmcidade.focus(); return false; } if (confirm("Você deseja mesmo cadastrar está cidade?")) { location.href="cidade.php";} else { return true; } } </script> Talvez o erro sej eu estar usando este JS junto com o o evento Onsubmit.... Espero que alguém possa me ajudar.... -
Olá galera, estou programando uma página e inseri nela um calendário, porém somente prte dele é exibido....segue o código , caso algué possa me ajudar... <?php session_start(); if ($_SESSION['autentica']<>'foifoifoifoi'){ header('location:../aviso.php?id=1'); } ?> <html> <head> <title>Assoc - Associação Social Canaã</title> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> <style type="text/css"> <!-- @import url(../../Fisk/classes.css); --> </style> <script language="JavaScript" type="text/JavaScript"> <!-- function MM_reloadPage(init) { //reloads the window if Nav4 resized if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) { document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }} else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload(); } MM_reloadPage(true); //--> </script> <style type="text/css"> <!-- @import url("../../classes.css"); .style15 {color: #000fff} --> </style> <meta http-equiv="content-language" content="en" /> <meta http-equiv="content-type" content="text/html;charset=utf-8" /> <meta name="copyright" content="R. Schoo" /> <link rel="stylesheet" media="screen" href="styles/vlaCal-v2.1.css" type="text/css" /> <link rel="stylesheet" media="screen" href="styles/vlaCal-v2.1-adobe_cs3.css" type="text/css" /> <link rel="stylesheet" media="screen" href="styles/vlaCal-v2.1-apple_widget.css" type="text/css" /> <script type="text/javascript" src="jslib/mootools-1.2-core-compressed.js"></script> <script type="text/javascript" src="jslib/vlaCal-v2.1-compressed.js"></script> <!-- You could also include the uncompressed versions for developing purposes: <script type="text/javascript" src="jslib/mootools-1.2-core.js"></script> <script type="text/javascript" src="jslib/vlaCal-v2.1.js"></script>--> <style> body { cursor: default; text-align: left; font-family: calibri, arial, sans-serif; font-size: 13px; margin: 0; padding: 5px; } table th { vertical-align: top; } input { text-align: center; font-family: calibri, arial, sans-serif; font-size: 13px; background-color: white; border: 1px solid; border-color: #abadb3 #dbdfe6 #e3e9ef #e2e3ea; padding: 2px; } input:focus, input:hover { border-color: #5794bf #b7d5ea #c7e2f1 #c5daed; } .pickerImg { position: absolute; margin-left: -16px; margin-top: 5px; cursor: pointer; } .infoBox { background-color: #fefdec; border: 1px solid #edebcd; padding: 6px; margin-bottom: 20px; } </style> <script type="text/javascript"> window.addEvent('domready', function() { new vlaDatePicker('exampleI'); }); </script> </head> <body> <table width="740" border="0" align="center" cellpadding="0" cellspacing="0"> <tr> <td><div align="center"><p align="center"><img src="../../imagem/topo_site1.bmp" alt="Assoc" width="155" height="110"></p> <p align="left"> </p> </div></td> </tr> <tr> <td><div align="center"><a href="../index.php"><strong><font color="#0000FF"><img src="../../imagem/inicio.png" alt="Início" width="80" height="62" border="0" longdesc="index.php"></font></strong></a> <font color="#0000FF"><strong> <a href="../cadastros.php"><img src="../../imagem/cadastro3.png" alt="Cadastros" width="78" height="62" border="0"></a> </strong></font> <font color="#0000FF"><strong> <a href="../buscar.php"><img src="../../imagem/pesquisa.png" alt="Buscar" width="76" height="61" border="0"></a><a href="../impressao.php"><img src="../../imagem/cadastro.png" alt="Relatórios" width="76" height="62" border="0"></a><a href="../administracao.php"> <font color="#0000FF"><img src="../../imagem/adm.png" alt="Administração" width="72" height="61" border="0"></font></a> </strong></font><strong> </strong><font color="#0000FF"><strong> <a href="../../aviso.php?id=2"><img src="../../imagem/logoff-48.png" alt="Sair" width="51" height="51" border="0"></a></strong></font></div></td> </tr> <tr> <td bgcolor="#CCCCCC"><div align="center"><strong>olá <?php echo $_SESSION['usuario']; ?>, Hoje é <?php echo $_SESSION['data']; ?> </strong></div></td> </tr> <tr> <td><div align="center"> <p align="left"><strong> <a href="../cadastros.php"><span class="style16 style1 style15">Cadastros</span></a>><span class="style16 style1 style15"><span class="style16 style1 style15">Movimentação financeira:</span></strong></p> <form name="form1" method="post" action="financeiro2.php"> <table width="95%" border="0"> <tr> <td><strong>Movimentado por:</strong></td> <td><input name="responsavel" type="text" id="textfield412" value="<?php echo $_SESSION['usuario']; ?>" size="35" readonly="true"></td> </tr> <tr> <td><strong>Tipo de Movimentação:</strong></td> <td><select name="tipo" id="tipo"> <option value="ENTRADA">ENTRADA</option> <option value="SAIDA">SAIDA</option> </select></td> </tr> <tr> <td><strong>Mês:</strong></td> <td><select name="mes" id="mes"> <option value="JANEIRO">JANEIRO</option> <option value="FEVEREIRO">FEVEREIRO</option> <option value="MARCO">MARCO</option> <option value="ABRIL">ABRIL</option> <option value="MAIO">MAIO</option> <option value="JUNHO">JUNHO</option> <option value="JULHO">JULHO</option> <option value="AGOSTO">AGOSTO</option> <option value="SETEMBRO">SETEMBRO</option> <option value="OUTUBRO">OUTUBRO</option> <option value="NOVEMBRO">NOVEMBRO</option> <option value="DEZEMBRO">DEZEMBRO</option> </select></td> </tr> <tr> <td><strong>Valor:</strong></td> <td><input name="valor" type="text" id="valor" size="10"></td> </tr> <tr> <td><strong>Número da nota fiscal:</strong></td> <td> <table cellpadding="0"> <tr> <td><input id="exampleI" name="date" type="text" style="width: 80px;" maxlength="10" /></td> </tr> </table> <tr> <td><strong>Destino:</strong></td> <td><textarea name="destino" rows="5" cols="30"></textarea></td> </tr> <tr> <td><strong>data de pagamento:</strong></td> <td><input name="data" type="text" id="data"></td> </tr> <tr> <td><br></td> </tr> <tr> <td></td> </tr> <tr> <td colspan="2"><div align="center"> <input type="submit" name="Submit" value="Cadastrar"> <input type="reset" name="Submit2" value="Limpar"> </div></td> </tr> </table> </form> <p align="left"> </p> </div></td> </tr> <tr> <td bgcolor="#CCCCCC"><div align="center"><strong>Assoc - Associação Social Canaã</strong></div></td> </tr> </table> </body> </html> Peço desculpas cado esta postagem esteja no no lugar errado... Desja já agradeço....
-
Caros colegas, estou desenvolvendo um página em php+mysql e estou com muitos probles com Notice: Undefined index <?php session_start(); if ($_SESSION['autentica']<>'foifoifoifoi'){ header('location:../aviso.php?id=1'); } ?> <html> <head> <title>Assoc - Associação Social Canaã</title> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> <style type="text/css"> <!-- @import url(file:///C|/servidor/www/Fisk/classes.css); --> </style> <script language="JavaScript" type="text/JavaScript"> <!-- function MM_reloadPage(init) { //reloads the window if Nav4 resized if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) { document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }} else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload(); } MM_reloadPage(true); //--> </script> <style type="text/css"> <!-- @import url("../classes.css"); --> </style> <link href="../../classes.css" rel="stylesheet" type="text/css"> </head> <body> <table width="740" border="0" align="center" cellpadding="0" cellspacing="0"> <tr> <td><div align="center"><p align="center"><img src="../../imagem/topo_site1.bmp" alt="Assoc" width="155" height="110"></p> <p align="left"> </p> </div></td> </tr> <tr> <td><div align="center"><a href="../index.php"><strong><font color="#0000FF"><img src="../../imagem/inicio.png" alt="Início" width="80" height="62" border="0" longdesc="index.php"></font></strong></a> <font color="#0000FF"><strong> <a href="../cadastros.php"><img src="../../imagem/cadastro3.png" alt="Cadastros" width="78" height="62" border="0"></a> </strong></font> <font color="#0000FF"><strong> <a href="../buscar.php"><img src="../../imagem/pesquisa.png" alt="Buscar" width="76" height="61" border="0"></a><a href="../impressao.php"><img src="../../imagem/cadastro.png" alt="Relatórios" width="76" height="62" border="0"></a><a href="../administracao.php"> <font color="#0000FF"><img src="../../imagem/adm.png" alt="Administração" width="72" height="61" border="0"></font></a> </strong></font><strong> </strong><font color="#0000FF"><strong> <a href="../../aviso.php?id=2"><img src="../../imagem/logoff-48.png" alt="Sair" width="51" height="51" border="0"></a></strong></font></div></td> </tr> <tr> <td bgcolor="#CCCCCC"><div align="center"><strong>olá <?php echo $_SESSION['usuario']; ?>, Hoje é <?php echo $_SESSION['data']; ?> </strong></div></td> </tr> <tr> <td><div align="left"> <p><strong><a href="../buscar.php">Buscar</a>>Buscar no cadastro de aluno:</strong></p> <form name="form1" method="post" action=""> <table width="99%" border="0" align="center" bordercolor="#999999" class="campos"> <tr> <td colspan="7"><div align="center">Ordem: <select name="ordem" class="campos"> <option selected value="ASC">Crescente</option> <option value="DESC">Decrescente</option> </select> Buscar: <select name="tabela" class="campos"> <option value="nome">Por nome</option> <option value="nascimento">Por Nascimento</option> <option value="naturalidade">Por naturalidade</option> <option value="sexo">Por Sexo</option> <option value="escolaridade">Por escolaridade</option> <option value="bairro">Por bairro</option> <option value="cidade">Por cidade</option> <option value="cadastro">Por cadastrador</option> <option value="datacadastro">Por data de cadastro</option> </select> <br> Texto: <input name="texto" type="text" class="campos" size="70"> <input type="submit" name="Submit" value="OK"> </div> </td> </tr> <tr> <td colspan="7"> </td> </tr> <tr> <td height="19"><div align="left" class="style2">Nome:</div> </td> <td><div align="left" class="style2">Data de Nascimento:</div> </td> <td><div align="left" class="style2">CPF:</div> </td> <td><div align="left" class="style2">Nome da Mãe:</div> </td> <td><div align="left" class="style2">opções</div> </td> </tr> <?php require("../../banco.php"); $ordem=$_POST['ordem']; $tabela=$_POST['tabela']; $texto=$_POST['texto']; if ($texto<>'') { $sql= "select * from aluno where ".$tabela." like '%".$texto."%' GROUP BY nome ".$ordem; } else { $sql = "SELECT * FROM aluno GROUP BY nome ".$ordem; } $cunhu_proprio=mysql_query($sql); while ($dados=mysql_fetch_array($cunhu_proprio, MYSQL_ASSOC)){ if ($a==1){ echo "<tr><td bgcolor=#F3F3F3>".$dados['nome']."</td>"; echo "<td bgcolor=#F3F3F3>".$dados['nascimento']."</td>"; echo "<td bgcolor=#F3F3F3>".$dados['cpf']."</td>"; echo "<td bgcolor=#F3F3F3>".$dados['mae']."</td>"; echo "<td><a href=../editar/aluno.php?codigo=".$dados['cod'].">EDITAR</a><td><a href=../excluir/aluno2.php?codigo=".$dados['cod'].">EXCLUIR</a></td>"; ?> <?php $a=0; }else{ echo "<tr><td bgcolor=#BFDFFF>".$dados['nome']."</td>"; echo "<td bgcolor=#BFDFFF>".$dados['nascimento']."</td>"; echo "<td bgcolor=#BFDFFF>".$dados['cpf']."</td>"; echo "<td bgcolor=#BFDFFF>".$dados['mae']."</td>"; echo "<td><a href=../editar/aluno.php?codigo=".$dados['cod'].">Editar</a><td><a href=../excluir/aluno2.php?codigo=".$dados['cod'].">EXCLUIR</a></td></td>"; ?> <?php $a=1; } } ?> </table> <div align="center"><font color="#0000FF"><strong>Numero de Registros encontrados: <?php echo mysql_num_rows($cunhu_proprio); ?></strong></font> </div> </form> <p> </p> </div></td> </tr> <tr> <td bgcolor="#CCCCCC"><div align="center"><strong>Assoc - Associação Social Canaã</strong></div></td> </tr> </table> </body> </html> Notices encontrados: Notice: Undefined index: ordem in c:\arquivos de programas\easyphp1-7\www\assoc 04-05\home\cadastros\matricula.php on line 123 Notice: Undefined index: tabela in c:\arquivos de programas\easyphp1-7\www\assoc 04-05\home\cadastros\matricula.php on line 124 Notice: Undefined index: texto in c:\arquivos de programas\easyphp1-7\www\assoc 04-05\home\cadastros\matricula.php on line 125 Notice: Undefined variable: a in c:\arquivos de programas\easyphp1-7\www\assoc 04-05\home\cadastros\matricula.php on line 139 Fernando Miranda Notice: Undefined index: nascimento in c:\arquivos de programas\easyphp1-7\www\assoc 04-05\home\cadastros\matricula.php on line 156 08979735693 Notice: Undefined index: mae in c:\arquivos de programas\easyphp1-7\www\assoc 04-05\home\cadastros\matricula.php on line 160 como faço para corrigir iss no código??? Abs....
-
VLW GALERA!!! ALTEREI O CÓDIGO AQUI E DEU CERTINHO!!! MUITO OBRIGADO!!
-
Boa tarde galera!! Estou desenvolvendo um sistem em PHP+ MySql e estou com dificuldades para exibir os dados já inseridos em um textarea segue o codigo para que vocês possam analisar e me ajudar a descobrir onde está o erro.... <tr> <td> <p><strong>ATIVIDADES DESENVOLVIDAS:</strong></p> <p> </td> <td colspan="2"> <textarea rows="8" cols="45" style="border-style: solid; border-width: 1px; padding-left: 4px; padding-right: 4px; padding-top: 1px; padding-bottom: 1px" name="atividades" value="<?php echo $linha['atividades']?>"</textarea></td> <td width="220"> </td> </tr> Abraços.