Jump to content
oscomglas

Email problems

Recommended Posts

Hai All,

I have been going over several topics but no solution found yet.

Using Ubuntu 16.04.6 LTS

PHP 7.0.33

oscommerce-2.3.4.1

Mail is working (machine acts also as mailserver)

PHP mail also tested and works.

<?php

$to      = 'xxxxx@yyyyy.zz';
$subject = 'Test mail';
$message = 'Eh test !';
$headers = 'From: xxxxxxx@yyyyy.zz' . "\r\n" .
      'Reply-To: xxxxxxx@yyyyy.zz' . "\r\n";

mail($to, $subject, $message, $headers);

?>

However I can select smtp or sendmail but no mail is send:

I see a log entry with sendmail log

mail.log

Sep 11 22:06:23 site sendmail[24010]: x8BK6NYc024010: from=www-data, size=247, class=0, nrcpts=0, msgid=<201909112006.x8BK6NYc024010@yyyy.zz>, relay=www-data@localhost
Sep 11 22:11:22 site sendmail[24567]: x8BKBMI1024567: from={name}, size=101, class=0, nrcpts=1, msgid=<201909112011.x8BKBMI1024567@yyyy.zz>, relay=root@localhost

Looks weird that the from is the owner or just a name....

Relay is also weird I would expect local IP or something like that.. oscom log just tels me mails are send.... no errors...

I hope someone knows what to do to get it running... Install was smooth no errors....

Chrs P.

 

 

Share this post


Link to post
Share on other sites

Try installing the Phoenix version (see my signature below).  2.3.4.1 is a little dated and might be causing the problems you're having.

Dan

Share this post


Link to post
Share on other sites

According to W3SCHOOLS php mail tutorial, there are two must have headers:

Quote

// Always set content-type when sending HTML email
$headers = "MIME-Version: 1.0" . "\r\n";
$headers .= "Content-type:text/html;charset=UTF-8" . "\r\n";


// More headers
$headers .= 'From: <webmaster@example.com>' . "\r\n";
$headers .= 'Cc: myboss@example.com' . "\r\n";

mail($to,$subject,$message,$headers);

Could this be the cause?

 

Share this post


Link to post
Share on other sites

Hai Dan,

Yes I updated to the phoenix version and now mail (and security checks) are working ok.....Thxs for the hint.

However I noticed that after adding the Dutch language my admin screen is in Dutch but in the main shop I have no language selection ?

Any hints on that part ?

winkel/includes/languages/
total 48
drwxr-xr-x  4 root root  4096 Sep 13 15:44 .
drwxr-xr-x 11 root root  4096 Sep 13 14:39 ..
drwxr-xr-x  4 root root  4096 Sep 13 15:44 dutch
-rw-r--r--  1 root root 16600 Sep 13 15:44 dutch.php
drwxr-xr-x  4 root root  4096 Sep 13 14:39 english
-rw-r--r--  1 root root 11184 Sep 13 14:39 english.php

winkel/admin/includes/languages/
total 56
drwxr-xr-x  4 root root  4096 Sep 13 15:43 .
drwxr-xr-x 10 root root  4096 Sep 13 14:39 ..
drwxr-xr-x  4 root root  4096 Sep 13 15:43 dutch
-rw-r--r--  1 root root 23285 Sep 13 15:43 dutch.php
drwxr-xr-x  4 root root  4096 Sep 13 14:39 english
-rw-r--r--  1 root root 16057 Sep 13 14:39 english.php

Chrs.

 

 

 

 

Share this post


Link to post
Share on other sites

I stand corrected ..... indeed there are two files:

winkel/includes/languages/dutch/modules/navbar_modules/nb_languages.php

winkel/includes/languages/english/modules/navbar_modules/nb_languages.php

Share this post


Link to post
Share on other sites

Yes...this isn't ready for prime time yet but have a read. It'll tell you about the Navigation Bar and how to install the NavBar modules etc.  Play around with it.

Navigation and the NavBar Modules

Dan

 

Share this post


Link to post
Share on other sites

Super got it working now thnxs fo the tip....

Really appreciate your quick response.

Now we can start playing with it further and see if it does what we want hi.....

Chrs

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×