salve ragazzi! ho questa form mail creata da hotscript in automatico ma non riesco a farla funzionare poichè ogni volta che compilo tutti i campi mi da questo errore:
Parse error: syntax error, unexpected '=' in /web/htdocs/manuelabuzzerra.raccontidamore.it/home/contact.php on line 13
in
la form è questa:
<?php
// Website Contact Form Generator
// http://www.tele-pro.co.uk/scripts/contact_form/
// This script is free to use as long as you
// retain the credit link
// get posted data into local variables
$EmailFrom = "miamail@iiii.it";
$EmailTo = "";
$Subject = "email dal sito";
$Nome = Trim(stripslashes($_POST['Nome']));
$Cognome = Trim(stripslashes($_POST['Cognome']));
$E-Mail = Trim(stripslashes($_POST['E-Mail']));
$TESTO = Trim(stripslashes($_POST['TESTO']));
// validation
$validationOK=true;
if (Trim($Nome)=="") $validationOK=false;
if (Trim($E-Mail)=="") $validationOK=false;
if (Trim($TESTO)=="") $validationOK=false;
if (!$validationOK) {
print "<meta http-equiv=\"refresh\" content=\"0;URL=error.htm\">";
exit;
}
// prepare email body text
$Body = "";
$Body .= "Nome: ";
$Body .= $Nome;
$Body .= "\n";
$Body .= "Cognome: ";
$Body .= $Cognome;
$Body .= "\n";
$Body .= "E-Mail: ";
$Body .= $E-Mail;
$Body .= "\n";
$Body .= "TESTO: ";
$Body .= $TESTO;
$Body .= "\n";
// send email
$success = mail($EmailTo, $Subject, $Body, "From: <$EmailFrom>");
// redirect to success page
if ($success){
print "<meta http-equiv=\"refresh\" content=\"0;URL=ok.htm\">";
}
else{
print "<meta http-equiv=\"refresh\" content=\"0;URL=error.htm\">";
}
?>
e questa è la parte in html:
<div class="content">
<form method="POST" action="contact.php">
I campi contrassegnati con l'asterisco (*) sono obbligatori </p>
Nome:*
<input type="text" name="Nome">
</p>
Cognome:
<input type="text" name="Cognome">
E-Mail:*
<input type="text" name="E-Mail">
TESTO:*
<textarea name="TESTO"></textarea>
<input type="submit" name="Submit" value="Submit">
</form>
</div>
</div>
mi dite come fare esattamente per farla funzionare correttamente perfavore?