Dynamic email address via custom field is lost when form loads via AJAX
We exchanged brief notes on Twitter, but I was hoping you could take a quick look at this here.
Your tutorial was awesome, and exactly what I needed. I run a site for people who organize ski leases, snowpals.org/leases. People submit their ski leases to me, and then I post them so people can contact the organizers. Your plugin was perfect because each ski lease should have its own contact form that goes to an email address unique to that page.
I’m running into a problem though, because I’m loading the form into a lightbox that pops up via AJAX. Following your tutorial, I have email address stored in a custom field on each post, and when I embed the form on the page via editing my WP template, everything works great! Dynamic email is pulled, form works, email is sent. However, when I embed the form in the lightbox, for some reason, the email address isn’t pulled and the value attribute is empty:
Any idea how to solve this? The alternative is just leaving the form visible on the page when you load it, but it would be so much cleaner to have it in a lightbox that can be triggered when people hit a ‘Contact’ button.
- The topic ‘Dynamic email address via custom field is lost when form loads via AJAX’ is closed to new replies.