Skip Navigation

[Resolved] Custom fields in email confirmation

This support ticket is created 5 years, 8 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 - -
13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 - -

Supporter timezone: America/New_York (GMT-04:00)

This topic contains 2 replies, has 2 voices.

Last updated by TJS3586 5 years, 8 months ago.

Assisted by: Christian Cox.

Author
Posts
#1241091

Hi,
We have a form successfully adding new custom post type with a relationship to another content type item. We'd like the CRED form to pass the value of the relationship in the email notification we have set up - is that possible?

This is the Expert code for the field we're trying to share in the email confirmation:

<label>Performance date</label>
[cred_field field='@sita-performance_sita-ticket.parent' class='form-control' output='bootstrap' select_text='--- not set ---' urlparam='performance']

Any guidance is much appreciated. Thank you

#1241151
Screen Shot 2019-05-08 at 1.58.48 PM.png

Hi, you can use the Fields and Views button above the email notification editor to insert a Post Title shortcode (or any similar shortcode) in your email contents. In the popup, you can use the "Post Selection" tab to choose "A post related to the current post, set by a Types relationship". See the attachment here. You will select the parent post in your one-to-many relationship to display the selected parent post in the email notification.

#1241174

Interestingly I was able to add the Title of the related item using your instructions but wasn't able to use the GUI interface to add the custom field I was using. I had limited "Post selection" options, with nothing regarding relationships available.

BUT I was able to trick things into working by manually changing my field from this:
[types field='performance-date' style='text' format='F j, Y'][/types]
to this:
[types field='performance-date' style='text' format='F j, Y' item="@sita-performance_sita-ticket.parent"][/types]
I just mimicked the code from the Title field that was working.

Thanks you!