Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- $nome = stripslashes($_POST['nome']);
- $cognome = stripslashes($_POST['cognome']);
- $mittente = stripslashes($_POST['mittente']);
- $richiesta = stripslashes($_POST['richiesta']);
- $sms = '
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
- <html>
- <head>
- <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
- <title>Contatti</title>
- </head>
- <body style="margin:0px;">
- <table cellpadding="0" cellspacing="0" style="height:100%;width:500px;">
- <tr>
- <td style="height:100%;padding:20px;vertical-align:top;">
- <table>
- <tr><td colspan="2">
- <img src="Url della tua immagine personalizzata" alt="" />
- </td>
- </tr>
- <tr><td width="110"><b>Nome:</b></td>
- <td width="300">'.$nome.'</td></tr>
- <tr>
- <td><b>Cognome:</b></td>
- <td>'.$cognome.'</td></tr>
- <tr>
- <td><b>E-mail:</b></td>
- <td>'.$mittente.'</td></tr>
- <tr>
- <td><b>Richiesta:</b></td>
- <td>'.$richiesta.'</td></tr>
- </table></td></tr>
- </table>
- </body>
- </html>';
- $headers = "From: $nome $cognome <$mittente>n";
- $headers .= "Content-Type: text/html; charset=iso-8859-1n";
- if(mail($_POST['destinatario'], $oggetto, $sms, $headers)){
- echo '&controllo=invio avvenuto con successo.';
- }
- else{
- echo '&controllo=errore: e-mail non inviata.';
- }
- ?>
Add Comment
Please, Sign In to add comment