Pesquisar na Comunidade
Mostrando resultados para as tags ''htm''.
Encontrado 1 registro
-
Olá pessoal eu estou com um probleminha estou criando um fomulário de contato, mas estou com um probleminha na pagina de agradecimentos, eu queria colocar ela como "privada" para que ninguém acessa-se ela sem preencher o formulário, me disseram que tem como fazer usando Sessão mas n faço ideia de como fazer isso, bem eu queria que quando a pessoa preenchesse o formulário e enviasse, ela fosse redirecionada para a pagina de agradecimentos e dps voltasse para a pagina do formulário, mas que a partir dai ela não pudesse mais voltar a pagina de agradecimento sem preencher o formulário de novo, espero que de pra alguém me ajudar. é que estou começando agora na Areá de php e não entendo muito. BEM MEU CÓDIGO ESTA ASSIM ESSE ÉO FORMULARIO <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <meta http-equiv="X-UA-Compatible" content="ie=edge"> <title>Conato</title> </head> <body> <center> <form name="formulario" action="receber.php" method="POST"> <h1>ENTRE EM CONTATO.</h1> <label>Nome:</label> <input type="text" name="nome" placeholder="Insira um Nome."><br/><br/> <label>E-mail:</label> <input type="email" name="Email" placeholder="Insira um E-mail."><br/><br/> <label>Assunto:</label> <input type="text" name="assunto" placeholder="Insira um Assunto"><br/><br/> <label>Mensagem</label><br> <textarea name="mensage" placeholder="Insira uma Mensagem"></textarea><br> <input type="submit" value="Enviar"> <input type="reset" value="Limpar"> </form> </center> </body> </html> ESSE EO CÓDIGO PHP <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <meta http-equiv="X-UA-Compatible" content="ie=edge"> <title>Document</title> </head> <body> <?php $noome=$_POST['nome']; $emaill=$_POST['Email']; $aasunto=$_POST['assunto']; $menssagem=$_POST['mensage']; ?> <?php $to = "voupormeuemailaqui"; $subject = "Assunto do Formulerio"; $message = "<strong>NOME:</strong> $noome<br /> <strong>E-mail: </strong> $emaill<br /><br /> <strong>Assunto: </strong> $aasunto<br /><br /> <strong>Mensagem: </strong> $menssagem<br /><br />"; $header = "MIME-Version: 1.0\n"; $header.="Content-type: text/html; charset=iso-8859-1\n"; $header .="From: $eemail\n"; mail($to, $subject, $message, $header); header ("location: enviado.html"); ?> </body> </html> E ESSA ÉA PAGINA DE AGRADECIMENTO <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <meta http-equiv="X-UA-Compatible" content="ie=edge"> <title>Obrigado</title> </head> <body> <center> <h1>OBRIGADO POR ENTRAR EM CONTATO!</h1> <h2>EM BREVE RESPONDEREMOS SUA DUVIDA.</h2> <a href="index.html">Clique Aqui para voltar</a> </center> </body> </html> ESPERO QUE POSSAM ME AJUDAR!
- 2 respostas
