I have a real estate site with communities, agents, and listings (separate CPTs). The contact form on each listing currently goes to one person, but I’d like to configure routing to go to an agent based on the community the listing belongs to.
Hi Jodzeee. Is there a reason you cannot use the ID in your routing rules, instead of the post title? If there is, then there may be a way around this, but it would not use the custom field merge tag, but this filter instead:
Let us know if you cannot use the post ID. Thank you.
Nah, I can use the ID, but it got me wondering how to do it - like if it wasn’t a hidden field and I actually wanted to show the title. I’ll just us the ID and call it a day Thanks for your help!
Thanks @jodzeee. If the information you need is in the custom fields in the post meta, you can get it out with the {custom_field} merge tag. If you have a reference to the information you need (like the ID in this case) then you will need to use the gform_field_value filter to take that reference from the custom field, then look up the information you need (post title) and populate the field. It’s not quite as easy as the {custom_field} merge tag.