Bonjour,

j'ai un formulaire, qui doit me permettre d'envoyer un mail quand je clique sur un bouton, voici mon code :
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
Ext.ns('PI');
	PI.wContact = Ext.extend(Ext.Window, {
			initComponent : function() {
 
			var contact = {
					xtype:'form'
					,id: 'mail-form'
					,url:'scripts/sendMail.php'
					,frame:true 
					,defaults:{anchor:'95%'} 
					,items:[{
						xtype: 'textfield'
						,id: 'contactEmail'
						,vtype: 'email'
						,fieldLabel: 'Votre e-mail'
						,allowBlank: false
						,msgTarget: 'side'
						,blankText: 'e-mail non valide'
						},
						{
						xtype: 'textfield'
						,id: 'contactObjet'
						,fieldLabel: 'Objet'
						,allowBlank: false
						,msgTarget: 'side'
						},
						{
						xtype: 'textarea'
						,id: 'contactMsg'
						,height: 350
						,hideLabel: true
						,allowBlank: false
						,msgTarget: 'side'
						}
					]
					,buttonAlign: 'center' 
					,buttons: [
						{
						xtype: 'button'
						,text: 'Envoyer'
						,icon: 'img/email_go.png'
						,bubbleEvents: ['envoyer']
						,handler: function(){this.fireEvent('envoyer');}
						},{
						xtype: 'button'
						,text: 'Annuler'
						,icon: 'img/cross.png'
						,bubbleEvents: ['annuler']
						,handler: function(){this.fireEvent('annuler');}
						}
					]
 
			};
 
			var config = {
				id: 'wContact'
				,itemId: 'wContact'
				,width: 750
				,height: 500
				,minWidth: 300
				,minHeight: 200
				,layout: 'fit' 
				,border: false 
				,frame: true 
				,title: 'Contact' 
				,items: [contact]
				}	// fin config
 
 
			// apply config
			Ext.apply(this, Ext.apply(this.initialConfig, config));
 
			// call parent
			PI.wContact.superclass.initComponent.apply(this, arguments);
			this.show();
			}	// fin function initComponent
			,listeners: {
				envoyer : function() {
						Ext.getCmp('mail-form').getForm().submit();
						this.close();
				}
				,annuler : function() {this.close();}
			}
 
	}); 	// fin PI.wContact
 
 
 
	Ext.reg('wContact', PI.wContact);
Quand je clique sur envoyer, la fenetre se ferme bien, mais je ne reçois jamais de mail.
et comment passer les paramètres saisis dans les champs du formulaire au script php ?
le script php d'envoi de mail fonctionne bien quand je le lance seul, je reçois bien un mail.

qu'est ce qui cloche?

Merci,

Nicolas