|
 Patrick Franke - 2006-04-25 11:58:46
Hi Folks,
do I need to combine the two classes above if I want to send an html email with an attachment and dislaying an error information?
I use the smtp class so send mails and if an error occurs I write a protocol in a mysql database. Now I want to send the mail in html and attach a pdf-file. Is it necessary to combine the two classes? If yes how, if not where is the piece of code that displays the error information?
Thanks for your support...
Patrick
 Patrick Franke - 2006-04-25 13:51:48 - In reply to message 1 from Patrick Franke
Sorry, I forgot something else...
I attached a PDF-File but I can't open the received PDF. The following error is diplayed (translated from german):
Can't open the file because it is damaged (i.e. if it was send by email and was wrong decoded)...
How can I solve the problem? Is it possible to send pdf?
 Manuel Lemos - 2006-04-26 02:09:57 - In reply to message 1 from Patrick Franke
The email_message_class uses the mail() function to send messages. If the mail() function works well in your system, you just need to use that class.
Otherwise you need to use the smtp_message_class subclass that uses the smtp_class class for delivery instead of the mail() function.
See the test_smtp_message.php example to learn how to set the email_message object for SMTP delivery. See the test_html_mail_message.php example to learn how to compose HTML messages with attachments.
 Manuel Lemos - 2006-04-26 02:13:03 - In reply to message 2 from Patrick Franke
Message corruption is often caused by the PHP option magic_quotes_runtime . Make sure it set to Off in your php.ini configuration. Use the phpinfo() PHP command to check what it its current value.
 Adnan Maqbool - 2006-04-29 12:19:42 - In reply to message 4 from Manuel Lemos
Can any one provide a sample script which can help me in knowing that how to use this class. I just want to send a mail with attachment of microsoft word document.
Thnx
 Manuel Lemos - 2006-04-29 18:00:11 - In reply to message 5 from Adnan Maqbool
Take a look at the test_attachment_message.php example script that comes with the class.
 Patrick Franke - 2006-05-03 05:16:44 - In reply to message 6 from Manuel Lemos
Hi Manuel,
the classes woks now as designed... But I have a problem with one of the mails I want to send. The status said: "it was not possible to read line from the SMTP server: the server disconnected". Do you have any ideas how I can solve the problem with the disconnection?
Patrick
 Manuel Lemos - 2006-05-03 06:16:44 - In reply to message 7 from Patrick Franke
This may be due to a premature error accepting your message.
Try setting the smtp_debug option to 1 to see the SMTP dialog so you can see when the server disconnects .
 Patrick Franke - 2006-05-04 14:38:16 - In reply to message 8 from Manuel Lemos
Hi Manuel,
I have to send an email to an recipient with an german "ß" in his address and the debug mode give me the following information:
Resolving SMTP server domain "mailin04.sul.t-online.de"...
Connecting to host address "194.25.134.10"...
Connected to SMTP server "mailin04.sul.t-online.de".
S 220 mailin12.sul.t-online.de T-Online ESMTP receiver fssmtpd2025 ready.
C EHLO localhost
S 250-mailin12.sul.t-online.de ready.
S 250-SIZE 33554432
S 250-8BITMIME
S 250 HELP
C MAIL FROM:<turnier@xxx.de>
S 250 Ok.
C RCPT TO:<klemensannette.naß@xxx.de>
S 553 Error parsing recipient address.
Disconnected.
It seems that something went wrong with the "ß"... Is it the class or the server. The recepient told me that the address is correct.
------------------------------------------------------------------------
This was the debug notice with the error code "reached the end of data while reading from the SMTP server conection":
Resolving SMTP server domain "mx2.uni-frankfurt.de"...
Connecting to host address "141.2.22.205"...
Connected to SMTP server "mx2.uni-frankfurt.de".
S 220 urmel.rz.uni-frankfurt.de ESMTP Exim 4.50 Thu, 04 May 2006 16:35:29 +0200
C EHLO localhost
S 550 Who is it? It's me! It's me?!?
C HELO localhost
For me it seems that the server didn't accept the localhost...
Patrick
 Manuel Lemos - 2006-05-04 19:35:10 - In reply to message 9 from Patrick Franke
I have done some research and it seems that the SMTP server does not the support IMA (Internationalized Mail Addresses) extension.
According to some IETF drafts I read the work-around is to use PunyCode to encode non-ASCII characters of the local part of the e-mail address.
The SMTP class does not yet support either IMA SMTP extension or PunyCode. They are not RFC recommendations. They are just IETF drafts. I could try to implement them, but I would need to know which SMTP servers support non-ASCII characters in e-mail addresses so I can test them.
As for localhost rejection, if that is the problem, just set the localhost variable of the smtp_message_class object to the address of your host.
|