Closed timiwahalahti closed 7 years ago
Fixed build errors and handling of values which are arrays.
Previously fields with array values got saved wrongly because those were put throught esc_html
and wp_json_encode
. Removed these because add_post_meta
does serialization and added maybe_unserialize
with implode
.
Also introduced three new filters to change glue for implode:
wplf_email_array_field_implode_glue
wplf_{$form->post_name}_email_array_field_implode_glue
wplf_{$form->ID}_email_array_field_implode_glue
This is probably not intended behaviour
Brilliant stuff! Maybe we should pre-populate the email content with some sensible template containing %all-form-fields%
? Right now it's a bit too easy to accidentally save an empty content for the email
No wait. :) That's exactly what it already does. Nevermind.
I'm just gonna go ahead and merge.
Thank you so much!
Is this feature released?
Nope, the last release was released on Oct 24 and this was merged on Oct 26.
But we try to not break the master branch, so you can use that.
@anttiviljami @timiwahalahti should we do a release in the near future? There's bugfixes, new features and improvements. I think. GitHub kinda makes it hard to check that what does master contain that isn't in a release.
This PR adds metabox where user can change form header, subject and content of email. All form fields can be used everywhere and there's also few global details which can be used; submission-id, referrer, form-title, form-id, user-id, timestamp, datetime, language, all-form-data.
Test, translate and update documentation before merge.
In a way, relates to #37.