Problema enviando mail
| From: | marolijo at yahoo dot es | Date: | Fri, 24 Mar 2006 09:56:17 +0000 |
| Subject: | Problema enviando mail | ||
| Groups: | php.general.es | ||
| Request: | Send a blank email to general-es+get-58322@lists.php.net to get a copy of this message | ||
Hola, envio un mail con la funcion mail() y en el subject no me aparecen las
acentos, me aparecen X en su lugar.
El cuerpo es HTML y sale bien. En los headers tengo Content-type: text/html;
charset=iso-8859-1\r\n
alguna idea?
gracias
/* recipients */
$to = $row_correu['email'];
/* subject */
$subject = "Nova incorporació al catàleg > ";
$subject .= @$HTTP_GET_VARS["tipus"];
$subject .= " / ";
$subject .= @$HTTP_GET_VARS["localitat"];
/* To send HTML mail, you can set the Content-type header. */
$headers = "MIME-Version: 1.0\r\n";
$headers .= "Content-type: text/html; charset=iso-8859-1\r\n";
$headers .= "From: llll <mailto:sauleda@llll.com>
@llll.com";
$headers .= "\r\n";
do { ?>
<?php
echo "> ".$row_correu['id']." >
".$row_correu['email']."<br>";
$headers .= "Bcc: ".$row_correu['email']."\r\n";
?>
<?php } while ($row_correu = mysql_fetch_assoc($correu)); ?>
<?php
mail($to, $subject, $message, $headers);
mysql_free_result($correu);
?>
Pol Maresma - <mailto:pol@polnetwork.com>
pol@polnetwork.com
PolNetwork.com - Serveis d'Internet