questo è il mio form
- <form id="tariffe" method="post" action="mail_tariffe.php" name="form_tariffe" onsubmit="return ControlloForm_tariffe();">
- <label for="dete_a">Data di arrivo:</label>
- <input type="text" size="8" id="from" name="from" class="data" /><br />
- <label for="date_r">Data di partenza:</label>
- <input type="text" size="12" id="to" name="to" class="data" /><br/>
- <label for="info">Richieste di soggiorno:</label>
- <textarea tabindex="4" id="notes" name="notes" cols="10" rows="4"></textarea><br/>
- <label for="name">Nome e Cognome:</label>
- <input name="nome" type="text" tabindex="3" value="" size="30" maxlength="40" /><br/>
- <label for="city">CittĂ :</label>
- <input name="citta" type="text" tabindex="3" value="" size="30" maxlength="40" /><br/>
- <label for="telephone">Telefono:</label>
- <input name="telefono" type="text" tabindex="3" value="" size="30" maxlength="40" /><br/>
- <label for="email">Mail:</label>
- <input name="mail" type="text" tabindex="3" value="" size="30" maxlength="40" /><br/>
- <input tabindex="5" type="submit" id="invia" name="invia" value="invia" />
- </form>
questo è il mio script php
- <?php
- // L'INDIRIZZO DEL DESTINATARIO DELLA MAIL
- $to = "info@murgiaalbanese.it";
- // IL SOGGETTO DELLA MAIL
- $subject = "Prenotazione da www.murgiaalbanese.it";
- // COSTRUZIONE DEL CORPO DEL MESSAGGIO
- $body = "Contenuto del modulo di prenotazione:\n\n";
- $valore1=trim(stripslashes($_POST["mail"]));
- $body .= "Data di arrivo: " . trim(stripslashes($_POST["from"])) . "\n";
- $body .= "Data di Partenza: " . trim(stripslashes($_POST["to"])) . "\n\n";
- $body .= "Richieste di soggiorno: " . trim(stripslashes($_POST["notes"])) . "\n";
- $body = "Registrazione effettuata da:\n\n";
- $body .= "Nome e Cognome: " . trim(stripslashes($_POST["nome"])) . "\n";
- $body .= "CittĂ : " . trim(stripslashes($_POST["citta"])) . "\n";
- $body .= "Telefono: " . trim(stripslashes($_POST["telefono"])) . "\n";
- $body .= "Mail: " . trim(stripslashes($_POST["mail"])) . "\n";
- // INTESTAZIONI SUPPLEMENTARI
- $headers = "From: Contatto dal Sito";
- // INVIO DELLA MAIL
- if(@mail($to, $subject, $body, $headers)) { // SE L'INOLTRO E' ANDATO A BUON FINE...
- ?>
- <script language="Javascript">
- alert('La Richiesta stata inoltrata con successo.');
- window.location.href="http://www.murgiaalbanese.it/home.html";
- </script>
- <?php
- } else {// ALTRIMENTI...
- ?>
- <script language="Javascript">
- alert('Si sono verificati problemi nell invio della richiesta.');
- window.location.href="http://www.murgiaalbanese.it/tariffe.html";
- </script>
- <?php
- }
- ?>
la richiesta viene inoltrata con successo, ma ripeto, nella mail non trovo le prime tre informazioni... confido in un vostro aiuto.