The problem I’m running into is in the case when a user clicks to edit registration details for a previous event. It pre-fills the info from the most recent event and a user would be led to believe that their answers were changed for their previous registrations.
Hence, I was wondering if there is a way to only pre-populate those custom fields on a NEW event registration to avoid confusion for users who may think their previous registration answers were changed. Otherwise I will disable the snippet to pre-populate the fields because I don’t want to confuse users. We run a dog training center and often have the same person sign up for various classes with different dogs, so this could cause issues for them. Thanks for any ideas!
Hey Josh, to achieve the goal of only autofilling all the info if it’s not a revisit, can I just place your code and it work properly? Or do I need to place all the codes from the 2016 post in addition to your code on March 4th 2020? And do I need to make it a plugin or can I just place it on custom php file? thanks
You copy the code snippet once onto your site, not every iteration of it.
Generally speaking, you’d add the code into a plugin. If you just place it into a custom php file then you’ll need to make a way for WordPress to load the file and execute the code at the correct hook point. To keep things simple we recommend this guide:
The support post ‘WP user integration to auto-fill custom fields ONLY on a NEW registration’ is closed to new replies.
Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.