Mailing html sur fond noir

Fermé
joachim - 17 janv. 2008 à 16:13
 Parasitor - 2 juil. 2008 à 10:33
Bonjour,

J'envoie un mailing en html, avec une image, du texte en blanc, et un fond noir.
Le problème est que sur certains types de boîtes mails (notamment gmail et yahoo), l'image apparait correctement, mais le fond noir ne s'affiche pas. Ce qui empêche donc de lire le texte blanc (blanc sur blanc...)
Le test sur hotmail par contre est concluant : tout s'affiche correctement.

Auriez-vous la solution ?

Pour plus de précisions : le mail est envoyé à 20000 personnes depuis le plugin Mail It sur Filemaker pro 8.5 et voici le code html :

<!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>IS THERE STILL A SPACE FOR A GLOBAL CRITIQUE ?</title>
<style type="text/css">
<!--
body {
background-color: #000000;
}
-->
</style></head>

<body>
<div>
<div align="right"><img src="cid:bk.gif@3C031C48.7833.1849.B811.E0A3A8E7CE79" width="34" height="20" /></div>
</div>
<div class="centrage">
<p align="center"><img src="cid:img.jpg@4D5BA9E8.BC42.9B44.B7AB.91637BFE5088" width="557" height="766" />"</p>

<p align="center"><span style="line-height:12 px; font-family:Arial, Helvetica, sans-serif; font-size:7pt; font-weight:normal; font-stretch:condensed; color:#FFFFFF">If you no longer wish to receive this kind of message, please return this message after writing “unsubscribe” in the subject field.</span></p>
</div>
</body>
</html>

merci !!
A voir également:

9 réponses

Dalida Messages postés 6728 Date d'inscription mardi 14 mai 2002 Statut Contributeur Dernière intervention 11 janvier 2016 920
17 janv. 2008 à 16:55
<!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>IS THERE STILL A SPACE FOR A GLOBAL CRITIQUE ?</title>
</head>
<body style="background-color:#000">
<div>
<div align="right"><img src="cid:bk.gif@3C031C48.7833.1849.B811.E0A3A8E7CE79" width="34" height="20" /></div>
</div>
<div class="centrage">
<p align="center"><img src="cid:img.jpg@4D5BA9E8.BC42.9B44.B7AB.91637BFE5088" width="557" height="766" />"</p>

<p align="center"><span style="line-height:12 px; font-family:Arial, Helvetica, sans-serif; font-size:7pt; font-weight:normal; font-stretch:condensed; color:#FFFFFF">If you no longer wish to receive this kind of message, please return this message after writing “unsubscribe” in the subject field.</span></p>
</div>
</body>
</html> 
1
Dalida Messages postés 6728 Date d'inscription mardi 14 mai 2002 Statut Contributeur Dernière intervention 11 janvier 2016 920
17 janv. 2008 à 16:23
salut,

mets le style dans la balise.
<body style="background-color:#000">

0
Reivax962 Messages postés 3671 Date d'inscription jeudi 16 juin 2005 Statut Membre Dernière intervention 11 février 2021 1 011
17 janv. 2008 à 16:29
Bonjour,

En regardant comment était traduit un mail HTML sur le webmail de gmail, j'ai cru comprendre que la balise <body> était simplement remplacée par une balise <div>.
Donc le style ne s'applique plus.
Par contre, si tu le places directement dans la balise : <body style='background-color:black'>, ça devrait marcher, non ?

Xavier
0
ok, j'essaierai bien, mais j'ai oublié de dire que je n'y connaissais rien.
Où je peux inclure ces lignes?

Merci en tous cas !!
0

Vous n’avez pas trouvé la réponse que vous recherchez ?

Posez votre question
Mais d'intuition, j'ai corrigé le code comme suit, et ça ne marche pas sur gmail non plus :

<!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>IS THERE STILL A SPACE FOR A GLOBAL CRITIQUE ?</title>
<style type="text/css">
<body style='background-color:black'>
</style></head>

<body>
<div>
<div align="right"><img src="cid:bk.gif@3C031C48.7833.1849.B811.E0A3A8E7CE79" width="34" height="20" /></div>
</div>
<div class="centrage">
<p align="center"><img src="cid:img.jpg@4D5BA9E8.BC42.9B44.B7AB.91637BFE5088" width="557" height="766" />"</p>

<p align="center"><span style="line-height:12 px; font-family:Arial, Helvetica, sans-serif; font-size:7pt; font-weight:normal; font-stretch:condensed; color:#FFFFFF">If you no longer wish to receive this kind of message, please return this message after writing “unsubscribe” in the subject field.</span></p>
</div>
</body>
</html>
0
Reivax962 Messages postés 3671 Date d'inscription jeudi 16 juin 2005 Statut Membre Dernière intervention 11 février 2021 1 011
17 janv. 2008 à 16:58
Mauvaise intuition ;)

Fais plutôt comme Dalida te propose (oui, j'ai bien vu que vos messages se sont croisés)
0
ok, j'ai copier le code de Dalida, et la bonne nouvelle c'est que ça fonctionne nickel sur gmail.

Par contre, ça ne fonctionne plus sur yahoo, ni sur hotmail (les images s'affichent, mais pas le fond noir). Et sur free, on voit rien du tout.
0
On m'a gentillement conseillé aussi ce code, qui ne marche toujours pas sur hotmail... Mais qui marche sur gmail et outlook !
(je parle du fond noir)

Que faire pour que ça marche chez tout le monde ?!!

<body style='background-color:black;color:white'>
<div style='width:100%; background-color:black;color:white'>
<div align="right"><img src="cid: bk.gif@3C031C48.7833.1849.B811.E0A3A8E7CE79" width="34" height="20" /></div>
</div>
<div class="centrage">
<p align="center"><img src="cid:img.jpg@4D5BA9E8.BC42.9B44.B7AB.91637BFE5088 " width="557" height="766" />"</p>

<p align="center"><span style="line-height:12 px; font-family:Arial, Helvetica, sans-serif; font-size:7pt; font-weight:normal; font-stretch:condensed; color:#FFFFFF">If you no longer wish to receive this kind of message, please return this message after writing "unsubscribe" in the subject field.</span></p>
</div>
</body>
0
Salut, j'ai viens d'avoir le même problème que vous.
Plutôt que de forcer le fond noir j'ai contourné le problème en créant une cellule sans bordure 100% x 100% de fond noir.
J'y insère le contenu original du mail html et le tour est joué :


$html_message .= "<table border=\"0\" width=\"100%\" height=\"100%\" bgcolor=\"black\"><tr><td width=\"951\" height=\"359\"><p>";

$html_message .= $TON_E_MAIL_ORIGINAL

$html_message .= "</p></td></tr></table></html>";
0
Dalida Messages postés 6728 Date d'inscription mardi 14 mai 2002 Statut Contributeur Dernière intervention 11 janvier 2016 920
24 janv. 2008 à 20:17
salut,

je mettrais des guillemets (") au lieu des apostrophes (').
0