Email notification 3.0.0 configuration

Email notification worked in Classic 2.7.1, when a Contact or Submit form had “Send me a copy” or “Send me an email” it just worked. After setting up a test Omeka S 3.0.0 site, no emails. Looking at the mail instructions, I set up the /application/config/module.config.php to show (commenting out the original sendmail lines):

 #    'mail' => [ 
 #        'transport' => [
 #            'type' => 'sendmail',
 #            'options' => [],
 #        ],
 #        'default_message_options' => [
 #            'encoding' => 'UTF-8',
 #        ],
 #    ],
   'mail' => [
        'transport' => [
            'type' => 'smtp',
            'options' => [
                'name' => 'localhost',
                'host' => '127.0.0.1',
                'port' => '465', 
                'connection_class' => 'smtp',
                'connection_config' => [
                    'username' => 'admin@legacywinchester.org',
                    'password' => '***password***',
                    'ssl' => 'ssl',
                    'use_complete_quit' => true,
                ],
            ],
        ],
    ],

the username and port settings were suggested by my hosting provider, and I’ve checked that they work via mail client.

Observation: the collection module seems to process both a Contact and Submit-an-Item (both uploaded contact and video content appears to admins view) but an error is generated at the end…

Archivists Think Tank on FB helped me fix the syntax (missing commas) have people succeeded in getting email notification working? I am not stuck on SMTP but the sendmail default is not working either.

oops. It seems that the symbol for “commenting out” is the hashmark #.
so in Markdown it converts to #EMPHASIS
and three asterisks is italic-bold.

enabled .htaccess error reporting - not yet obvious how to fix; webhosting2050.is.cc is the hosting provider’s host…

  • Omeka S encountered an error

  • Laminas\Mail\Protocol\Exception\RuntimeException
    Could not open socket: stream_socket_client(): Peer certificate CN=webhosting2050.is.cc' did not match expected CN=127.0.0.1’

Details:

Laminas\Mail\Protocol\Exception\RuntimeException: Could not open socket: stream_socket_client(): Peer certificate CN=webhosting2050.is.cc' did not match expected CN=127.0.0.1’ in /home/legacywi/s2.legacywinchester.org/vendor/laminas/laminas-mail/src/Protocol/AbstractProtocol.php:210 Stack trace: #0 [internal function]: Laminas\Mail\Protocol\AbstractProtocol->Laminas\Mail\Protocol{closure}(2, ‘stream_socket_c…’, ‘/home/legacywi/…’, 214, Array) #1 /home/legacywi/s2.legacywinchester.org/vendor/laminas/laminas-mail/src/Protocol/AbstractProtocol.php(214): stream_socket_client(‘ssl://127.0.0.1…’, 0, ‘’, 30) #2 /home/legacywi/s2.legacywinchester.org/vendor/laminas/laminas-mail/src/Protocol/Smtp.php(186): Laminas\Mail\Protocol\AbstractProtocol->_connect(‘ssl://127.0.0.1…’) #3 /home/legacywi/s2.legacywinchester.org/vendor/laminas/laminas-mail/src/Transport/Smtp.php(398): Laminas\Mail\Protocol\Smtp->connect() #4 /home/legacywi/s2.legacywinchester.org/vendor/laminas/laminas-mail/src/Transport/Smtp.php(384): Laminas\Mail\Transport\Smtp->connect() #5 /home/legacywi/

(added '- ’ in front of # and ** above to see if we can avoid Markdown interpretation)

email works now thanks to suggestion from hosting provider and pointer from R.C. Miessler ! woo hoo! solution works if I replace the hostname instead of 127.0.0.1 in the ‘mail’ portion of the config script:

-----begin of snippet-----

‘mail’ => […

See More

Image may contain: text

Good to hear you figured it out. I’m not sure this is really unique to Omeka S or version 3.0.0 though: it doesn’t really handle mail differently than Classic by default. Both just rely on the server being set up to be able to deliver mail with the “sendmail” system, or else on the administrator to manually configure SMTP, as you’ve done here.

For future reference, you can use the “Preformatted text” button in the post editor to post things that should be presented exactly as-is and not Markdown-formatted. You can see that I edited your initial post to use that formatting.

This topic was automatically closed 250 days after the last reply. New replies are no longer allowed.