After a couple days of testing and five beta releases, I have released WordPress Google Form v0.61. This build supports multiple instances of the same form on a single page.
Why would you do this? It turns out, it is a fairly common request. A number of people have uses of the same form where some of the fields are hidden and preset (both features were added fairly recently) which allows them to present the form in different ways with seeded input while allowing the user to complete the rest. Because the form instances are all based on the same Google Form, they will have the exact same entry elements with the exact same attribute IDs. HTML does not allow multiple elements to have the same ID attribute, the behavior is unpredictable.
To support this new feature, a new parameter, uid, has been added to the wpgform shortcode. The uid parameter can be set to any string which is legal for an HTML element ID attribute. When the Google Form is processed, all of the attributes are modified to include the uid parameter to ensure they each have a unique value.
[wpgform id='879' uid='B-']
This release also addresses some issues with missing CAPTCHAs which would happen under certain circumstances. The jQuery generation is much cleaner now as well.
This morning I released version 4.6.2 of Email Users. This release addresses several translation issues and updates the Bulgarian translation. More importantly, this release adds an integration with ItThinx Groups! This new feature is one that has been requested several times and I finally had the time to work on it.
This morning I released beta-2 of WordPress Google Form v0.59. This build introduces one new feature (hidden fields) and fixes one limitation (validation rules).
Much like validation rules and placeholders, an input field can now be defined as hidden. When a field is defined as hidden, it does not appear to the user when they view the form and the value is set to a fixed value (e.g. a static string) or to something WordPress derives (e.g. the user’s IP address).
The format of the field name is exactly the same as used for validation and placeholders.
Validation has been improved and the limitation of one validation rule per field has been lifted. You can now define multiple validation rules for a single field. Simply enter the field name for each separate type of validation.
This morning I released version 4.6.0 of Email Users. This release addresses the problems with addresses appearing in the CC header instead of the BCC header which cropped up in v4.5.4 and v4.5.5. This version has gone through quite a bit of testing to ensure the problem with addresses was fixed. In addition to this critical fix, there are also a couple of minor new features now available. If you were running Email Users v4.6.0-beta-4, this version is nearly identical. The version is different and the default string for the new footer was trimmed eliminating the version number.
Significantly improved debug functionality to chase down mail header issues.
Check added to determine if wp_mail() has been overloaded by a theme or plugin.
Rewrite of mailusers_send_mail() fucntion to construct headers as arrays instead of as a single string. The string would sometimes not break correctly and recognize the Bcc: field.
This morning I formally release v0.58 of WordPress Google Form. Thanks to everyone who did testing of the various beta releases. The v0.58 release includes a number of improvements to deal with special characters either in responses or in questions.
Fixed bug when radio button and checkbox responses contained apostrophe characters.
Fixed bug when text entry box content contained an ampersand which ended up encoded in the Google sheet.
Fixed bug(s) with plugin settings which are controlled with checkboxes not being able to be unchecked.
Added Reset button to return plugin settings to their default state.
Fixed problem handling newlines (carriage returns) in textarea entries.
You can find the update on your WordPress Dashboard or in the WordPress Plugin Repository. The released version is functionally the same as beta-3, only the version number is different.
If you’ve been following the Email Users Support Forum, you are aware that for the past couple of days I have been chasing a bug which affects some users and places all of their intended recipient email addresses in the CC header instead of the BCC header.
This has been a challenging bug to find as it doesn’t happen on any of the systems I have access to. Fortunately I had a few users affected by this problem willing to help me and I appreciate their assistance. I am not sure how I would resolved this problem without their assistance. Again, thanks.
So what was the problem? The WordPress wp_mail() API allows you to pass extra header information as part of the mail content. Email Users makes use of this by constructing a BCC header which contains all of the email addresses for the intended recipients. The wp_mail() function supports headers as a single string or an array of headers, each header as an array element.
Up until this evening Email Users had constructed all email headers as a string. With a large number of email addresses this string could end up being very long. However, I don’t believe the length of the string had anything to do with the problem.
When wp_mail() receives headers as a string, it tries to intelligently decompose them. In some cases it appears that the string wasn’t splitting correctly which means the BCC field wasn’t ever seen. The “Bcc:” text became part of an email address which was subsequently discarded because it resulted in a bad address.
Email Users v4.6.0 has a rewrite of the mailusers_send_mail() function plus some new debug functionality which helps resolve these sorts of issues. Additionally, the new debug is under user control so can be turned on and off as needed.
I have just released beta-2 of WordPress Google Form v0,58. This update addresses a couple of significant issues, notably the inability to disable some of the default options.
The problem with the default settings based on checkboxes is described pretty well in this article by Devin Price. I was dealing with the essentially the same problem Devin describes although my solution is slightly different, his solution was helpful in fixing this problem.
While fixing this problem I also added a new Reset button which appears on the Advanced tab. This Reset button will reset the plugin to use the default settings.
This beta release also includes a fix to address the problem when an ampersand appears in a text box on a multi-page form. This problem was reported on WordPress Support Forum.