Hi,
I haven't been able to send newsletters for some time and upgraded the store from 4.6.x to 4.9.3 but the problem didn't go away. I checked the error logs and saw this;
PHP Warning: preg_replace_callback(): Compilation failed: invalid range in character class at offset 37 in /var/www/vhosts/example.com/httpdocs/app/addons/newsletters/func.php on line 117
Appearently, PCRE version has changed in PHP 7.3 and some regular expressions were rendered invalid thereafter.
I opened the mentioned file, found this line;
$regex = "/href=('|\")((?:http|ftp|https):\/\/[\w-\.]+[?]?[-\w:\+?\/?\.\=%&;~\[\]]+)/i";
Replaced with;
$regex = "/href=('|\")((?:http|ftp|https):\/\/[\w\-\.]+[?]?[-\w:\+?\/?\.\=%&;~\[\]]+)/i";
As you will notice, I escaped the dash ( - ) because after PHP 7.3, dashes that don't define a range needs to be escaped. Now I can send newsletters.
By the way, the same problem effects some other places in CS Cart as well.