Forum
Perch forms email recipients succeeds or fails, depending
When filling out email recipients for a contact form in "Form Options", one method of adding or editing recipients seems to cause the delivery of the emails to fail.
Say there are two emails entered, and a third is entered by placing the cursor wherever among those addresses, and then using the forward button to add a third at the end of the list. It seems that whatever address receives the initial cursor placement will fail and none of the emails will be delivered, though the contact form submission is received and the thank you email delivered.
It works to type in the additional addresses in the front of the entry text box. Another method that succeeds is to have the addresses properly typed in a text editor, and then to cut and paste into the recipients box.
The use case where I anticipate problems are where, say, 10 addresses are already entered and the site editor uses a cursor to move back and forth, eliminating some addresses and adding others wherever they appear in the list.
Anybody else experience this?
Diagnostics report:
Diagnostics report
HEALTH CHECK
Perch is up to date
PHP 5.6.16 is up to date
MySQL 5.6.23-cll-lve is up to date
Image processing available
SUMMARY INFORMATION
Perch: 2.8.19, PHP: 5.6.16, MySQL: 5.6.23, with PDO
Server OS: Linux, cgi-fcgi
Installed apps: content (2.8.19), assets (2.8.19), categories (2.8.19), perch_forms (1.8.3), perch_members (1.4)
App runtimes: <?php $apps_list = array( 'content', 'categories', 'perch_forms', 'perch_members', ); ?>
PERCH_LOGINPATH: /perch
PERCH_PATH: /home/wtowersa/public_html/testing/perch
PERCH_CORE: /home/wtowersa/public_html/testing/perch/core
PERCH_RESFILEPATH: /home/wtowersa/public_html/testing/perch/resources
Image manipulation: GD
PHP limits: Max upload 128M, Max POST 128M, Memory: 256M, Total max file upload: 128M
Resource folder writeable: Yes
DOCUMENT_ROOT: /home/wtowersa/public_html/testing
HTTP_HOST: testing.willamettetowers.com
REQUEST_URI: /perch/core/settings/diagnostics/
SCRIPT_NAME: /perch/core/settings/diagnostics/index.php
Here's my initial successful Debug, where the two recipients do receive the submitted form:
Debug Message
SELECT * FROM perch2_pages WHERE pagePath='/contact.php' LIMIT 1
SELECT DISTINCT settingID, settingValue FROM perch2_settings WHERE userID=0
SELECT * FROM perch2_forms WHERE formKey='contact' LIMIT 1
Building message with Dollar template
Sent email: "Action Gram received from Virginia WT" to recipient1@comcast.net, recipient2@comcast.net
Using email template: /home/wtowersa/public_html/testing/perch/core/emails/.txt (txt)
Building message with Dollar template
Sent email: "Thank you from Willamette Towers" to submittor@comcast.net
INSERT INTO perch2_forms_responses(responseJSON,formID,responseIP,responseSpamData) VALUES('{\"fields\":{\"name\":{\"attributes\":{\"id\":\"name\",\"type\":\"text\",\"required\":\"true\",\"label\":\"Name\",\"placeholder\":\"Name is required\"},\"value\":\"Virginia WT\"},\"unit\":{\"attributes\":{\"id\":\"unit\",\"type\":\"text\",\"label\":\"Unit\",\"required\":\"true\",\"placeholder\":\"Unit number or affiliation with WT is required\"},\"value\":\"1202\"},\"email\":{\"attributes\":{\"type\":\"email\",\"id\":\"email\",\"label\":\"Email\",\"placeholder\":\"Email address is required.\"},\"value\":\"submittor@comcast.net\"},\"phone\":{\"attributes\":{\"type\":\"text\",\"id\":\"phone\",\"label\":\"Phone\",\"placeholder\":\"Phone is not required\"},\"value\":\"\"},\"message\":{\"attributes\":{\"type\":\"textarea\",\"id\":\"message\",\"required\":\"true\",\"label\":\"Message\",\"placeholder\":\"Your message here\",\"textile\":\"true\",\"editor\":\"markitup\"},\"value\":\"Two email addresses recipients typed in.\"}},\"files\":[],\"page\":{\"id\":\"5\",\"title\":\"Contact Us\",\"path\":\"\\/contact.php\",\"navtext\":\"Contact Us\"}}','6','71.63.161.51','{\"fields\":{\"honeypot\":\"\"},\"environment\":{\"CONTENT_LENGTH\":\"1103\",\"CONTENT_TYPE\":\"multipart\\/form-data; boundary=----WebKitFormBoundaryEIMXgTOnB7xoMKOV\",\"DOCUMENT_ROOT\":\"\\/home\\/wtowersa\\/public_html\\/testing\",\"GATEWAY_INTERFACE\":\"CGI\\/1.1\",\"HTTP_ACCEPT\":\"text\\/html,application\\/xhtml+xml,application\\/xml;q=0.9,image\\/webp,*\\/*;q=0.8\",\"HTTP_ACCEPT_ENCODING\":\"gzip, deflate\",\"HTTP_ACCEPT_LANGUAGE\":\"en-US,en;q=0.8\",\"HTTP_CACHE_CONTROL\":\"max-age=0\",\"HTTP_CONNECTION\":\"keep-alive\",\"HTTP_COOKIE\":\"_gat=1; _ga=GA1.2.777037835.1447783578\",\"HTTP_HOST\":\"testing.willamettetowers.com\",\"HTTP_ORIGIN\":\"https:\\/\\/testing.willamettetowers.com\",\"HTTP_REFERER\":\"https:\\/\\/testing.willamettetowers.com\\/contact\",\"HTTP_UPGRADE_INSECURE_REQUESTS\":\"1\",\"HTTP_USER_AGENT\":\"Mozilla\\/5.0 (Macintosh; Intel Mac OS X 10_10_4) AppleWebKit\\/537.36 (KHTML, like Gecko) Chrome\\/44.0.2403.130 Safari\\/537.36\",\"PATH\":\"\\/bin:\\/usr\\/bin\",\"PATH_TRANSLATED\":\"\\/home\\/wtowersa\\/public_html\\/testing\\/contact.php\",\"QUERY_STRING\":\"\",\"REDIRECT_STATUS\":\"302\",\"REMOTE_ADDR\":\"71.63.161.51\",\"REMOTE_PORT\":\"53556\",\"REQUEST_METHOD\":\"POST\",\"REQUEST_URI\":\"\\/contact.php\",\"SCRIPT_FILENAME\":\"\\/home\\/wtowersa\\/public_html\\/testing\\/contact.php\",\"SCRIPT_NAME\":\"\\/contact.php\",\"SERVER_ADDR\":\"75.98.175.114\",\"SERVER_ADMIN\":\"webmaster@testing.willamettetowers.com\",\"SERVER_NAME\":\"testing.willamettetowers.com\",\"SERVER_PORT\":\"80\",\"SERVER_PROTOCOL\":\"HTTP\\/1.1\",\"SERVER_SIGNATURE\":\"\",\"SERVER_SOFTWARE\":\"Apache\",\"UNIQUE_ID\":\"VncveUtir3IACzT39QQAAACW\",\"PHP_SELF\":\"\\/contact.php\",\"REQUEST_TIME_FLOAT\":1450651513.8463,\"REQUEST_TIME\":1450651513}}')
SELECT * FROM perch2_forms_responses WHERE responseID='229' LIMIT 1
No ids to log.
SELECT regionKey, regionHTML FROM perch2_content_regions WHERE regionPage='/contact.php' OR regionPage='*' ORDER BY regionPage DESC
Using template: /templates/forms/contact_wt.html
Array
(
[type] => 2
[message] => file_get_contents(/home/wtowersa/public_html/testing/perch/core/emails/.txt): failed to open stream: No such file or directory
[file] => /home/wtowersa/public_html/testing/perch/core/lib/PerchEmail.class.php
[line] => 95
)
When I insert the cursor in the address of recipient2 and then use the forward button to add a third address to the list, the Debug report shows that address as invalid.
Debug Message
SELECT * FROM perch2_pages WHERE pagePath='/contact.php' LIMIT 1
SELECT DISTINCT settingID, settingValue FROM perch2_settings WHERE userID=0
SELECT * FROM perch2_forms WHERE formKey='contact' LIMIT 1
Building message with Dollar template
Invalid address: recipient2@comcast.net
Using email template: /home/wtowersa/public_html/testing/perch/core/emails/.txt (txt)
Building message with Dollar template
Sent email: "Thank you from Willamette Towers" to submittor@comcast.net
INSERT INTO perch2_forms_responses(responseJSON,formID,responseIP,responseSpamData) VALUES('{\"fields\":{\"name\":{\"attributes\":{\"id\":\"name\",\"type\":\"text\",\"required\":\"true\",\"label\":\"Name\",\"placeholder\":\"Name is required\"},\"value\":\"Virginia WT\"},\"unit\":{\"attributes\":{\"id\":\"unit\",\"type\":\"text\",\"label\":\"Unit\",\"required\":\"true\",\"placeholder\":\"Unit number or affiliation with WT is required\"},\"value\":\"1202\"},\"email\":{\"attributes\":{\"type\":\"email\",\"id\":\"email\",\"label\":\"Email\",\"placeholder\":\"Email address is required.\"},\"value\":\"submittor@comcast.net\"},\"phone\":{\"attributes\":{\"type\":\"text\",\"id\":\"phone\",\"label\":\"Phone\",\"placeholder\":\"Phone is not required\"},\"value\":\"\"},\"message\":{\"attributes\":{\"type\":\"textarea\",\"id\":\"message\",\"required\":\"true\",\"label\":\"Message\",\"placeholder\":\"Your message here\",\"textile\":\"true\",\"editor\":\"markitup\"},\"value\":\"Third email Contact Form recipient is added using cursor and forward button to add to end of list.\"}},\"files\":[],\"page\":{\"id\":\"5\",\"title\":\"Contact Us\",\"path\":\"\\/contact.php\",\"navtext\":\"Contact Us\"}}','6','71.63.161.51','{\"fields\":{\"honeypot\":\"\"},\"environment\":{\"CONTENT_LENGTH\":\"1161\",\"CONTENT_TYPE\":\"multipart\\/form-data; boundary=----WebKitFormBoundary984IQliBLmXEuSTC\",\"DOCUMENT_ROOT\":\"\\/home\\/wtowersa\\/public_html\\/testing\",\"GATEWAY_INTERFACE\":\"CGI\\/1.1\",\"HTTP_ACCEPT\":\"text\\/html,application\\/xhtml+xml,application\\/xml;q=0.9,image\\/webp,*\\/*;q=0.8\",\"HTTP_ACCEPT_ENCODING\":\"gzip, deflate\",\"HTTP_ACCEPT_LANGUAGE\":\"en-US,en;q=0.8\",\"HTTP_CACHE_CONTROL\":\"max-age=0\",\"HTTP_CONNECTION\":\"keep-alive\",\"HTTP_COOKIE\":\"_gat=1; _ga=GA1.2.777037835.1447783578\",\"HTTP_HOST\":\"testing.willamettetowers.com\",\"HTTP_ORIGIN\":\"https:\\/\\/testing.willamettetowers.com\",\"HTTP_REFERER\":\"https:\\/\\/testing.willamettetowers.com\\/contact\",\"HTTP_UPGRADE_INSECURE_REQUESTS\":\"1\",\"HTTP_USER_AGENT\":\"Mozilla\\/5.0 (Macintosh; Intel Mac OS X 10_10_4) AppleWebKit\\/537.36 (KHTML, like Gecko) Chrome\\/44.0.2403.130 Safari\\/537.36\",\"PATH\":\"\\/bin:\\/usr\\/bin\",\"PATH_TRANSLATED\":\"\\/home\\/wtowersa\\/public_html\\/testing\\/contact.php\",\"QUERY_STRING\":\"\",\"REDIRECT_STATUS\":\"302\",\"REMOTE_ADDR\":\"71.63.161.51\",\"REMOTE_PORT\":\"53573\",\"REQUEST_METHOD\":\"POST\",\"REQUEST_URI\":\"\\/contact.php\",\"SCRIPT_FILENAME\":\"\\/home\\/wtowersa\\/public_html\\/testing\\/contact.php\",\"SCRIPT_NAME\":\"\\/contact.php\",\"SERVER_ADDR\":\"75.98.175.114\",\"SERVER_ADMIN\":\"webmaster@testing.willamettetowers.com\",\"SERVER_NAME\":\"testing.willamettetowers.com\",\"SERVER_PORT\":\"80\",\"SERVER_PROTOCOL\":\"HTTP\\/1.1\",\"SERVER_SIGNATURE\":\"\",\"SERVER_SOFTWARE\":\"Apache\",\"UNIQUE_ID\":\"VncwT0tir3IACTkE-3QAAAAT\",\"PHP_SELF\":\"\\/contact.php\",\"REQUEST_TIME_FLOAT\":1450651728.8805,\"REQUEST_TIME\":1450651728}}')
SELECT * FROM perch2_forms_responses WHERE responseID='230' LIMIT 1
No ids to log.
SELECT regionKey, regionHTML FROM perch2_content_regions WHERE regionPage='/contact.php' OR regionPage='*' ORDER BY regionPage DESC
Using template: /templates/forms/contact_wt.html
Array
(
[type] => 2
[message] => file_get_contents(/home/wtowersa/public_html/testing/perch/core/emails/.txt): failed to open stream: No such file or directory
[file] => /home/wtowersa/public_html/testing/perch/core/lib/PerchEmail.class.php
[line] => 95
)
I'm not sure I understand your situation. Are you talking about the basic text input field you enter email addresses into?
Yes, the Apps > Forms > (contact form in this case) > Form Options > Sending email >email address(es) text input.
Ok. That's just a basic text field. There's no way for Perch to do anything differently based on where you place your cursor.
If I copy the following from my Debug message and copy it into the textarea used when creating a thread for this forum using the triple-tilde method of showing as code, one can see a small box with a top row containing "00" and a lower row containing "ID" at the place where I placed the cursor when using the form options email address text box. If I publish to the forum, this small symbol is not apparent.
I tried taking a screen shot of this, but for some reason that did not take.
I have never encountered this before, and that is the only lead I have at this time as to why the address does not read as a proper email address.
Yes, this must be a pretty obscure issue. I wish I knew a way to show it more obviously.
Yes, you have some sort of zero-width character in the middle of the word "comcast".
This happened when editing in Opera:
Version: 34.0.2036.25 - Opera is up to date Update stream: Stable System: Mac OS X 10.10.4 64-bit
I now find that when editing in Chrome and Firefox, the same problem does not occur.
Sorry to bug you, best wishes in 2016, and thank you for Perch!