Tell us what you are trying to do?
When I add a prospective event to a venue with an add post form, I want the venue to receive an email. I hoped to use the venue's email address field in the post form, but cannot add related fields there,
I am able to automatically display the venue's name (Post title of venue) with the "parent ID", but would like to choose the venue's email address too.
I can add the email address to the post that is created, but then the venue will not receive a notification of the client's request.
Is there any documentation that you are following?
Yes, I have been looking for a whole day to find a solution on your website.
Is there a similar example that we can see?
This is one venue: hidden link
This is the post form for a prospective event for this venue: hidden link
What is the link to your site?
The development site: hidden link
Is the post form on the page where the event is ? Meaning you're filling out the form on the event page.
If so then you can simply create a generic email field and for the value you will add [types field='my-field'][/types] where my-field is the slug of the email field that is used on the events page.
From there you should be able to setup an email notification for this field. If not then you will need to switch the form to expert mode and under that generic email field you will add persist: 1
Thank you for your answer. The email address comes from the venue page. It is not generic. It should be transferred from the venue to the event.
Venue 1: hidden link
Venue 2: hidden link
If you scroll down, the venue email address is visible. You can see it is different for each venue.
The link above the email address is to fill a Post Form, but I still see now way how to add that to the post form in a way it will trigger a notification when the post is saved.
I've created a custom shortcode and added it to your site called [get_parent_email] . This custom shortcode was added to the generic email field in your form at the link below. hidden link
The field is called email. However for this field to be available in the notifications you must add persist: 1 to the generic field structure when you're editing the form in expert mode.
Given that your form is simple then it should be easy to switch to the expert mode. However you won't be able to switch back without losing some of the changes to your form structure.
Please let me know how best you want to proceed with this.
That kind of works. But we run into the problem that the one posting the form can change the email of the venue. I would like to have it fixed (like the name of the venue on top of the form) or even invisible