Forum

configuration d'env...
 
Notifications
Retirer tout

configuration d'envoi émail

48 Posts
3 Utilisateurs
0 Reactions
162.3 {numéro}K Vu
(@babynus)
Posts: 14952
Membre Admin
 

So, it confirms that headers are identical in both cases (working and not working).

The only significant difference is the message body.

So please, could you try 2 tests :

1) In /model/persistence/SqlElement.php, add 1 line after line 2473, this way :

  public function getMailDetail () {
    return "OK";

and test sending mail.

2) copy the attaches SqlElement.php file into /model/persistence
and test again.

Thanks.


 
Posté : 27 Juil PM 16:077
ameur
(@timoumi)
Posts: 32
Active Member
Début du sujet
 

I added line " return "OK";" after public function getMailDetail () { (Line 2743)
the message error in log file :

2013-07-27 16:27:28 ----- DEBUG ----- mail()
2013-07-27 16:27:28 ----- DEBUG ----- to=************@gmail.com
2013-07-27 16:27:28 ----- DEBUG ----- title=[My Own Project'Or RIA] message from admin : Project #1
2013-07-27 16:27:28 ----- DEBUG ----- message=

[My Own Project'Or RIA] message from admin : Project #1

test

OK

2013-07-27 16:27:28 ----- DEBUG ----- headers=MIME-Version: 1.0
Content-Type: text/html; charset=utf-8
From: ********@***.tn
Reply-To:
*********@****.tn
Content-Transfer-Encoding: 8bit
X-Mailer: PHP/5.3.10
2013-07-27 16:27:31
** ERROR ** ERROR **
2013-07-27 16:27:31 ** ERROR ** on file 'C:wampwwwprtoolprojector.php' at line (855)
2013-07-27 16:27:31 ** ERROR ** cause = mail() [function.mail]: SMTP server response: 451 See http://pobox.com/~djb/docs/smtplf.html.
2013-07-27 16:27:31 ----- DEBUG ----- resultMail=
2013-07-27 16:27:31 ** ERROR ** Error sending mail
2013-07-27 16:27:31 ** ERROR ** SMTP Server : smtp.*****.tn
2013-07-27 16:27:31
** ERROR ** SMTP Port : 25
2013-07-27 16:27:31
** ERROR ** Sendmail path :
2013-07-27 16:27:31
** ERROR ***** Mail stored in Database : #12

To resolve this issue ,would you mind to tell me about your web-container (easyphp, wamp, xampp, version, and your project'or ria version ... :silly:


 
Posté : 27 Juil PM 18:077
(@babynus)
Posts: 14952
Membre Admin
 

Can you try to copy the attached SqlElement.php file into /model/persistence
and test again (after unziping it !).
Thanks.


 
Posté : 27 Juil PM 19:077
ameur
(@timoumi)
Posts: 32
Active Member
Début du sujet
 

always the same error on project module when i try to send mail.
log file:
2013-07-27 18:04:59 ----- DEBUG ----- mail()
2013-07-27 18:04:59 ----- DEBUG ----- to=*********@**.**
2013-07-27 18:04:59 ----- DEBUG ----- title=[My Own Project'Or RIA] message from admin : Project #1
2013-07-27 18:04:59 ----- DEBUG ----- message=[My Own Project'Or RIA] message from admin :<br /> Project #1google

Project
#1
  id   #1
  name   test
  type   Fixed
Price
  customer   
  bill
contact 
 
  project
code 
 
  contract
code 
 
  is sub-project
of 
 
  manager   admin
  color   
  status   recorded
  health
status 
 
  fix
planning 
 
  done      
  closed      
  description   
Notes

2013-07-27 18:04:59 ----- DEBUG ----- headers=MIME-Version: 1.0
Content-Type: text/html; charset=utf-8
From: *********@**.**
Reply-To: *********@**.**
Content-Transfer-Encoding: 8bit
X-Mailer: PHP/5.3.10
2013-07-27 18:04:59 ** ERROR ** ERROR **
2013-07-27 18:04:59
** ERROR ** on file 'C:wampwwwprtoolprojector.php' at line (855)
2013-07-27 18:04:59
** ERROR ** cause = mail() [function.mail]: SMTP server response: 451 See http://pobox.com/~djb/docs/smtplf.html.
2013-07-27 18:04:59 ----- DEBUG ----- resultMail=
2013-07-27 18:04:59
** ERROR ** Error sending mail
2013-07-27 18:04:59
** ERROR ** SMTP Server : smtp.**.tn
2013-07-27 18:04:59 ** ERROR ** SMTP Port : 25
2013-07-27 18:04:59 ** ERROR ** Sendmail path :
2013-07-27 18:04:59 ** ERROR ** Mail stored in Database : #19


 
Posté : 27 Juil PM 20:077
(@babynus)
Posts: 14952
Membre Admin
 

Another try : always with the provided SqlElement.php, change /tool/projector.php and add

	$messageBody = wordwrap($messageBody, 70);

at line 589.
It should give :

function sendMail($to, $subject, $messageBody, $object=null, $headers=null, $sender=null, $boundary=null)  {
	$paramMailSmtpUsername = Parameter::getGlobalParameter('paramMailSmtpUsername');
	$paramMailSmtpPassword = Parameter::getGlobalParameter('paramMailSmtpPassword');
	$messageBody = wordwrap($messageBody, 70);
	if (! $paramMailSmtpUsername or ! $paramMailSmtpPassword) {
	  return sendMailAnonymous($to, $subject, $messageBody, $object, $headers, $sender, $boundary);	
	} else {
	  return sendMailAuthentified($to, $subject, $messageBody, $object, $headers, $sender, $boundary);
	}
}

and try again...


 
Posté : 27 Juil PM 20:077
ameur
(@timoumi)
Posts: 32
Active Member
Début du sujet
 

thank you very much for your attention but there are the same error :woohoo:


 
Posté : 28 Juil AM 00:077
(@babynus)
Posts: 14952
Membre Admin
 

Hi,

I don't have any more idea on Project'Or RIA side.
My last advice is to try another smtp server.
You can for instance try gmail smtp.
You just need a google account.

Parameters are :
smtp host : ssl://smtp.gmail.com
smtp port : 465
smtp login : your google account (a gmail address)
smtp password : your google password


 
Posté : 28 Juil AM 00:077
ameur
(@timoumi)
Posts: 32
Active Member
Début du sujet
 

I want to ask a question, is that sending email is activated in different modules for your personel Project'or ria :angry:


 
Posté : 28 Juil AM 02:077
ameur
(@timoumi)
Posts: 32
Active Member
Début du sujet
 

Hello friend
the problem has no relation with the SMTP server, simply because when i changed the variable "$ message" with 'hello' that is defined in projector.php :
Line code :

$ resultMail = mail ($ to, $ title, $ message, $ headers);

, the mail transfer with OK. 👿

Please could you help me
🙁


 
Posté : 28 Juil AM 04:077
(@babynus)
Posts: 14952
Membre Admin
 

Hi,

I suggested to try another smtp server because I never faced this issue, nor was it reported.
I send emails with no issue through several SMTP servers :
- smtp.free.fr
- ssl://smtp.gmail.com (worth a try)
- local sendMail on linux
The issue does not appear to be PHP stack dependant, as I have instances running correctly under :
- EasyPHP (windows)
- WAMP (windows)
- Zend (Linux)
- Default PHP on Ubuntu (Linux)

Really it is worth a try for you to test another SMTP server.
I think your smtp server has some limitations that I cannot identify.
The different tests I advised you were to remove any common limitations :
- remove all break lines in Message
- format all break lines in headers as nr
- truncate Message to 70 characters per line


 
Posté : 28 Juil PM 22:077
ameur
(@timoumi)
Posts: 32
Active Member
Début du sujet
 

I'm blocked, 🙁 could you send me a stable version of project'or ria with positive test of send mail.


 
Posté : 30 Juil AM 03:077
(@babynus)
Posts: 14952
Membre Admin
 

You can download a packaged version here :
projectorria.toolware.fr/files/EasyPHP.1...ojectOrRIA.3.4.0.zip

You just have to
- unzip archive
- run EasyPHP-12.1.exe (accept configuration changes as proposed)
- access to http://localhost/projectorria
- connect as admin/admin

But I don't think this will solve your issue.
You'll have to configure the smtp server, and if you continue with same server, issue won't be solved.

Please try another smtp server as previously suggested (for instance smtp.gmail.com).


 
Posté : 30 Juil PM 12:077
ameur
(@timoumi)
Posts: 32
Active Member
Début du sujet
 

Hello
Url :projectorria.toolware.fr/files/EasyPHP.1...ojectOrRIA.3.4.0.zip !!!
The requested URL /files/EasyPHP.1...ojectOrRIA.3.4.0.zip was not found on this server.


 
Posté : 31 Juil PM 15:077
(@babynus)
Posts: 14952
Membre Admin
ameur
(@timoumi)
Posts: 32
Active Member
Début du sujet
 

Finally It Works !

:woohoo: :woohoo:
:woohoo: :woohoo:
:woohoo: :woohoo:
:woohoo:
:woohoo: :woohoo:
:woohoo: :woohoo:
:woohoo: :woohoo:
:woohoo:
:woohoo: :woohoo:
:woohoo: :woohoo:
:woohoo: :woohoo:
:woohoo:


 
Posté : 2 Août PM 12:088
Page 3 / 4
Share:
Retour en haut