How to make my forms email the data to an email address
PermalinkI have inherited a website which is built on this platform.
The website has many contact forms but they do not seem to relay the data capture to an inbox.
I can see the data is sent to the CMS database which I can access from the dashboard so it is definitely being captured. But ideally this information needs to be delivered to an email address.
One of the fields in the form has an input field called notification email. But this just seems redundant i.e. no data is sent.
Can anyone help?
Thanks in advance

Are u saying if I choose to include a captcha (as is currently optional in the edit setup) this thing might actually fire off the email?
Its worth a shot anyway. I'll give it a go..
Is it possible that when the site built the mail server wasn't configurated??
Which files do I need to look at in order to establish the mail method?
This way I can check with the SOC Networks team, if it has been configured.
Thanks in advance..
The form has only a class and a name. It does not have an action, nor does it have a method..
So am I correct in assuming that concrete 5 is not set up to email the results to an inbox???
Does the site send out emails at all? like forgot password mails and such?
No the site no longer sends email, not even forgotten password etc
In dashboard email settings>SMTP Method
There are two options
I) Default PHP Mail Function [which is checked]
ii) External SMTP Server
Can you try putting the credentials of a known working SMTP Server into the config and see if it sends then?
Yeh think the php mailer function does its job. They get logged and the data is captured in the db. But somewhere along the line the mails stopped coming in.
I'm just looking through 4 years of historical correspondence and I now know for sure that emails used to get sent and received. During that time however the website has resided on different servers.
So, I'm left to think that the stmp mail server is no longer in place on the same (web) server as in dashboard>STMP method the default php mail script is checked. Does this not indicate that the mail server, when it worked, was local??
It might be that the base_url that is set or the IP or whatever has changed and therefore the phpmailer refuses its work - BUT this should be logged somewhere in the error logs...
If you just switch over to the SMTP method and enter valid credentials of a working server (where there should be a SPF record for your domain to use that mailserver) - the mailings should work.
Anyway - php mailings are way easier considered "spam" by many blocklists, so using the SMTP method is better.
If there was (or should be) stmp mailserver set up, would these details be in the site.php config file?? Only I cant see any evidence of one in site.php
Again I think this was the most probable setup initially (all them years ago).
in site.php there might be settings regarding the URL or IP adress that could interfere.
If the php mailing method was activated, there is no need for a separate SMTP server, the php script just behaves "as if" it was a mailing server which is why php mailing is easily considered as not being trustworthy.
Please just try setting up a smtp account there and you will quickly see if it works.
And if the smtp is set up on a different server then choose external smtp method in dashboard?
So if this is managed by the stmp method in dashboard, and the method is set to the default php internal mail script - which I am assuming it always has been this way..
Does this mean the stmp would have been originally setup on the same server ie was local?
Am I right in thinking that php mail still using stmp??
1. in the past, mailing with php worked fine, which is always "local". If the hosting environment has changed somewhere over time, it might just be that this function is no more available in the new environment.
2. It was always using a working SMTP and someone switched the configuration to PHP
Thanks for clearing that up.
Really appreciate your guidance.
Many Thanks
Much appreciated.
And i have entered the details in the dashboard..
Still having the same issue however i.e. emails not being received.
When i look at the logs i find this might be interesting
12:03:07 PM sent_emails paulmorrison
**EMAILS ARE ENABLED. THIS EMAIL WAS SENT TO mail()**
12:03:07 PM exceptions paulmorrison
Mail Exception Occurred. Unable to send mail: Connection timed out
#0 /var/www/vhosts/uk.domain.com/httpdocs/concrete/libraries/3rdparty/Zend/Mail/Protocol/Smtp.php(167): Zend_Mail_Protocol_Abstract->_connect('tcp://10.128.6....')
#1 /var/www/vhosts/uk.domain.com/httpdocs/concrete/libraries/3rdparty/Zend/Mail/Transport/Smtp.php(199): Zend_Mail_Protocol_Smtp->connect()
#2 /var/www/vhosts/uk.domain.com/httpdocs/concrete/libraries/3rdparty/Zend/Mail/Transport/Abstract.php(348): Zend_Mail_Transport_Smtp->_sendMail()
#3 /var/www/vhosts/uk.domain.com/httpdocs/concrete/libraries/3rdparty/Zend/Mail.php(1194): Zend_Mail_Transport_Abstract->send(Object(Zend_Mail))
#4 /var/www/vhosts/uk.domain.com/httpdocs/helpers/mail.php(64): Zend_Mail->send(Object(Zend_Mail_Transport_Smtp))
#5 /var/www/vhosts/uk.domain.com/httpdocs/packages/kelway_forms/helpers/util.php(79): MailHelper->sendMail()
#6 /var/www/vhosts/uk.domain.com/httpdocs/packages/kelway_forms/tools/save_contact.php(51): KelwayFormsUtilHelper->sendEmailNotifications('3578', 'Contact', Array, 'kelway')
#7 /var/www/vhosts/uk.domain.com/httpdocs/concrete/startup/tools.php(29): include('/var/www/vhosts...')
#8 /var/www/vhosts/uk.domain.com/httpdocs/concrete/dispatcher.php(146): require('/var/www/vhosts...')
#9 /var/www/vhosts/uk.domain.com/httpdocs/index.php(5): require('/var/www/vhosts...')
#10 {main}
$host = ‘127.0.0.1'
i don't recognise the IP - what is that??
Is it something Zend uses? Please help..