Fiz um formulário contato.html como no script abaixo:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Fabiu Som - Contato</title>
<style type="text/css">
<!--
body,td,th {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 12px;
color: #CCCCCC;
}
body {
background-image: url(images/carbono.jpg);
}
-->
</style></head>
<body>
<table width="318" border="0" align="center" cellpadding="0" cellspacing="0">
<!--DWLayoutTable-->
<tr>
<td width="318" height="313" align="center" valign="middle"><p>Entre em contato com a Fabiu Som.</p>
<p>Deixe seu e-mail, suas criticas e sugestões, nós retornaremos no menor prazo o possível.</p> <form id="contato" name="contato" method="post" action="enviar.php">
<p align="center">Nome: </p>
<label></label>
<div align="center">
<p>
<input name="nome" type="text" id="nome" />
</p>
<p>E-mail:</p>
<p>
<label>
<input name="email" type="text" id="email" />
</label>
</p>
</div>
<p align="center">Telefone:</p>
<p align="center">
<label>
<input name="telefone" type="text" id="telefone" />
</label>
</p>
<p align="center">Críticas e sugestões:
<label></label>
</p>
<p align="center">
<textarea name="criticas" id="criticas"></textarea>
</p>
<p align="center">
<label>
<input type="submit" name="enviar" id="enviar" value="enviar" />
</label>
</p>
</form></td>
</tr>
</table>
</body>
</html>Como aprendi estudando um feito pelo Balala... fiz o formulário envio.php da seguinte maneira:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Fabiu Som - Enviar</title>
</head>
<body>
<?
$msg = "Mensagem enviada em " . date("d/m/Y") . ", os dados seguem abaixo: " . chr(13) . chr(10) . chr(10); //nessa linha, estará impresso em que data e hora foi enviado o formulário
$msg .= "nome : " . $nome . chr(13) . chr(10); //aqui o campo nome estará aparecendo
$msg .= "email : " . $email . chr(13) . chr(10); //campo email
$msg .= "telefone: " . $telefone . chr(13) . chr(10); //campo telefone
$msg .= "critica: " . $critica . chr(13) . chr(10); //critica
$Remetente = $email; //aqui, colocamos que o email digitado seja quem enviou o formulário, pode ser substituido por "Contato do Site", assim, sairá sempre que quem enviou o email, seja Contato do Site
mail("fabiusom@fabiusom.com.br", "Assunto do Email",$msg,"From: $Remetente\n");
?>
</body>
</html>Há algum erro que impeça o envio ou recebimento de e-mails?










