Problem with sending e-mail

9 months 3 weeks ago #320173 by ald
Replied by ald on topic Problem with sending e-mail
Joomla and CB have been updated.
Still it doesn't work that e-mail in CB is sent to php 7.3+.
PHP Mail has tried it. Test in joomla works.
CB gives out an error:


Is there a log file running CB on host? I could send it to you.
What do you think is the reason why CB can't send mail in PHP 7.3+ versions on our website?
Attachments:

Please Log in to join the conversation.

9 months 3 weeks ago #320180 by krileon
Replied by krileon on topic Problem with sending e-mail
Your host has disabled the function escapeshellarg and is likely why it's failing. You maybe able to remove it from the disabled function list yourself in your php.ini. Beyond that I don't know what more to tell you. Sending emails works perfectly fine on PHP 7.3. We've tested up to PHP 7.4.2 as working fine. Your issue is likely entirely specific to your environment.

We'll be considering updating to PHPMailer 6.x in a future release, but as it introduces major B/C breaks we can't and are currently using the latest 5.x release so there's nothing for us to do in regards to the mailer library we are using.

forge.joomlapolis.com/issues/8140


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.
The following user(s) said Thank You: ald

Please Log in to join the conversation.

9 months 3 weeks ago #320238 by ald
Replied by ald on topic Problem with sending e-mail
Passed the possible disabling of escapeshellarg function to hosting. I cannot enable it in PHP settings. Their answer is: "escapeshellarg() is disabled at system level for security reasons.
Please contact the developer. There is no need to use escapeshellarg(). There is no need to use shell calls at all, it is not safe.
Why not call PHPMailer from the Joomla kernel? Why keep 2 identical PHPMailer modules?"

Please Log in to join the conversation.

9 months 2 weeks ago #320253 by krileon
Replied by krileon on topic Problem with sending e-mail
escapeshellarg is used specifically for escaping. It is completely safe and it's not used how your host thinks it is. It's used in PHPMailer library to check if an email sender contains shell commands. There's no reason to disable escapeshellarg.

Why not call PHPMailer from the Joomla kernel? Why keep 2 identical PHPMailer modules?

Because Joomla didn't update often enough. We always use the latest compatible PHPMailer for security reasons. You need to understand that CB existed during Mambo days. This was before Joomla was even called Joomla. So when Joomla 2.x came out and we still supported Joomla 1.x we needed to provide the most secure means of emailing. That means we needed to provide our own up to date PHPMailer library. At this time though both Joomla 3.x and CB are using PHPMailer 5.2.28. So your issue should exist whether you email from CB or Joomla.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.
The following user(s) said Thank You: ald

Please Log in to join the conversation.

9 months 2 weeks ago #320259 by ald
Replied by ald on topic Problem with sending e-mail
When, we did a site on localhost with PHP 7.3.17 Joomla, Joomla + CB mail worked and works. We did not even assume that the hoster will have some problem.

Please, could give recommendations for the hoster, where CB could send mail to php 7.3+.

Please Log in to join the conversation.

9 months 2 weeks ago #320260 by krileon
Replied by krileon on topic Problem with sending e-mail
I've no idea what configuration on your hosts server is causing your issue. My best guess was just the error above. Your localhost doesn't have that function disabled since it's not disabled in PHP by default as there's literally no reason to since it's just an escaping function (it does not execute shell commands).

What doesn't make sense though is that function is only called for PHP Mail and Sendmail. It's not used for SMTP. So you shouldn't even be seeing that error. If you are it means SMTP is failing in general and Joomla is trying to fallback to PHP Mail. CB won't fallback; we simply just stop and error if possible.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in to join the conversation.

Moderators: beatnantkrileon
Time to create page: 0.475 seconds

Facebook Twitter LinkedIn