Login Form

#753 – the email send error 550 Maximum line length exceeded (see RFC 5322 2.1.1)

Posted in ‘BF Quiz’
This is a public ticket. Everybody will be able to see its contents. Do not include usernames, passwords or any other sensitive information.
Thursday, 19 November 2015 00:35 AEDT
sashido
Joomla! version: (3)

Hi Tim!

Hope you're doing well. Recently I've ran into this problem. The user cannot receive mail. I as admin get the emial failure notifications with the following text:

This message was created automatically by mail delivery software.



A message that you sent could not be delivered to one or more of its

recipients. This is a permanent error. The following address(es) failed:



sashido@rambler.ru

host 159.253.1.250 [159.253.1.250]

SMTP error from remote mail server after end of data:

Maximum line length exceeded (see RFC 5322 2.1.1)


What can I do about this error?

Thanks in advance!

Aleksandra
 
Thursday, 19 November 2015 18:32 AEDT 5'
Tim
BF Quiz Plus 3 Years, BF Survey 12 Months
Hi Aleksandra,
Haven't seen this issue before. Do you get this same delivery failure message when you send to a different email address?

regards

Tim
Follow us on twitter http://twitter.com/tamlynsoftware
Thursday, 19 November 2015 19:20 AEDT
sashido
No, actually this is the first one and the only one e-mail address.

I have made some modifications to the controller.php to style the emails(font-colors and some margins). Could that be the problem?

Best regards,
Aleksandra
 
Thursday, 19 November 2015 22:18 AEDT 5'
Tim
BF Quiz Plus 3 Years, BF Survey 12 Months
Hi Aleksandra,
It's possible that your modifications of fonts etc may have some impact.

I did some googling of RFC error code (RFC 5322 2.1.1), and apparently it will only allow 998 characters per line. When there are no line breaks, all the HTML is counted as a single line.
So the simple solution seems to be to add some line breaks in the email body.

regards

Tim
Follow us on twitter http://twitter.com/tamlynsoftware
Friday, 20 November 2015 00:10 AEDT
sashido
Could you please be more specific on "line breaks"? How should I break the line? I mean with the php code like /n or /r?

I have specifically modified this line:

$emailBodyIncorrect = "<div style='margin:20px; border: 1px dashed green;'><br><span style='padding-left: 60px; font-weight:bold;'>".JText::_("COM_BFQUIZPLUS_INCORRECT_ANSWERS")."</span><br>".$myIncorrect."<br></div>";

Could you please make an example of how I should break it into lines?

Best regards,
Aleksandra
 
Friday, 20 November 2015 18:06 AEDT 5'
Tim
BF Quiz Plus 3 Years, BF Survey 12 Months
Try using the ascii characters for a carriage return (%0D) and line feed (%0A). For example:
%0D%0A
Follow us on twitter http://twitter.com/tamlynsoftware
This ticket is closed, therefore read-only. You can no longer reply to it. If you need to provide more information, please open a new ticket and mention this ticket's number.
Go to top