Bonjour,

J'ai un problème d'appel a un fichier mail.php à partir d'un fichier contact.xml.
Si je pointe directement le fichier mail.php * monsite.com/mail.php je reçois un courriel. Mais si je passe par le formulaire xml je ne reçois rien même si le formulaire une fois appuyer le bouton envoyer m'indique que le message a bien été envoyé.

Voici le code du fichier contact.xml

Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
<?xml version='1.0' encoding='utf-8'?>
 
<contactform 
	formwidth="780"
	formheight="495"
 
	mailphpurl="mail.php"
	imageurl="images/contact.png"
	imagelink="http://www.monsite.com/"
	imagetarget="_blank"
	imagewidth="300"
	imageheight="455"
	imagepadding="15"
	imagesolidbackgroundcolor="0x1e1a17"
	imagesolidbackgroundopacity="0.9"
	imagesolidbackgroundrounded="20"
 
	imageshadowopacity="0.3"
	imageshadowblur="7"
	imageshadowcolor="0x000000"
	imageshadowdistance="2"
	imageshadowangle="90"
 
	mailphplink="mail.php"
 
	fieldbgcolor="0x1e1a17"
	fieldbgopacity="0.8"
	fieldbgrounded="15"
	fieldfontcolor="0xcccccc"
	fieldfontsize="13"
 
	errorbgcolor="0xffffff"
	errorbgopacity="0.9"
	errorfontcolor="0x333333"
	errorfontsize="13"
 
	infobgcolor="0x1e1a17"
	infobgopacity="0.9"
 
	btnbgcolor="0x111111"
	btnfontcolor="0xaaaaaa"
	btnfontsize="13"
 
	fonttype="Arial"
>
 
	<infotext>
	<![CDATA[<newsheadline2>Passez me voir!</newsheadline2><content><br/>
	Coordonnée: &nbsp; &nbsp;1st Pays, region<br/>
	Téléphone: &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; (000) 000-0000 <br/>
	Email: &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<a href="mailto:mail@gmail.com">&nbsp; mail@gmail.com</a><br/>
	Web: <a href="http://www.yoursite.com/">&nbsp; http://www.yoursite.com/</a></content>]]>
	</infotext>
 
	<name>
	S.V.P. Entrer votre nom
	</name>
 
	<email>
	Votre adresse email ici
	</email>
 
	<message>
	Votre message
	</message>
 
	<sendmail>
	Envoyer la requête
	</sendmail>
 
	<errorname>
	S.V.P. Entrer votre nom!
	</errorname>
 
	<erroremail>
	S.V.P. entrer une adresse email valide !
	</erroremail>
 
	<errorfield>
	S.V.P. entrer votre message!
	</errorfield>
 
	<finished>
	Merci de nous avoir envoyer un message!
	</finished>
 
	<notfinished>
	Erreur addresse courriel!
	</notfinished>
 
</contactform>

Maintenant voici le code du fichier mail.php Sur ce fichier, on a qu'à modifier la ligne * Your email hire * en théorie. Comme dit ci-haut si je pointe directement je reçois un courriel mais pas par le fichier contact.xml donc je crois que le problème ce situe de ce côté. Comme je ne suis pas expert en XML, je suis au bout de mes ressources.

Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
<?php
 
$your_name = $_REQUEST['nametxt'];
$email = $_REQUEST['emailtxt'];
$message = $_REQUEST['messagetxt'];
 
 
$recipient_email = "YOUR EMAIL HERE";
$donotreply_email = "DoNotReply@YOURWEBSITE.com";
$me = "YOURWEBSITE.com";
$me = "YOURWEBSITE.com";
 
$subject = "YOURWEBSITE.com message from " . $email;
//$headers = "From: " . $your_name . " <" . $email . ">\n";
//$headers .= 'Content-type: text/html; charset=iso-8859-1';
 
$content = "<html><head><title>Contact letter</title></head><body><br>";
$content .= "Name: <b>" . $your_name . "</b><br>";
$content .= "Email: <b>" . $email . "</b><br><hr><br>";
$content .= "Message: <b>" . $message . "</b><br>";
$content .= "<br></body></html>";
 
 
 
 
$forwardingthemessage = "$me
 
Has received the below message:
 
--------------------------------------------------
Name: $your_name
Email: $email
 
.........Message.........
 
$message
 
--------------------------------------------------
 
 
end of message";
 
 
 
 
 
 
$replymessage = "Hi $your_name
 
Thank you for your email.
 
We will follow up shortly.
 
Please DO NOT reply to this email.
 
Below is a copy of the message you submitted:
--------------------------------------------------
Name: $your_name
Email: $email
$message
--------------------------------------------------
 
Best regards
YOURWEBSITE.com";
 
 
 
 
 
 
mail("$recipient_email",
     "$subject",
     "$forwardingthemessage",
     "From: $email\nReply-To: $email");
 
 
mail("$email",
     "Receipt from $me",
     "$replymessage",
     "From: $donotreply_email\nReply-To: $donotreply_email");
 
 
 
 
 
 
?>
<html>
<body bgcolor="#000000">
<div align="center" style="margin-top:60px;color:#FFFFFF;font-size:11px;font-family:Tahoma;font-weight:bold">
 
Your message was sent. Thank you.
 
<BR><BR><BR>
 
<a href="javascript:history.back()"> <font color="FFFFFF"><---- Go Back</font> </a>
 
</div>
</body>
</html>
<!-- uncomment to resize the page -->	
<!-- <script>resizeTo(500, 500)</script> -->

Merci de votre aide à l'avance