Home › Forums › Front-end Issues › Front End Form to CPT data not saving › Reply To: Front End Form to CPT data not saving
Thanks for providing the data, your code looks great and I am surprised that you are having any issues at all.
Lets do some debugging to find out where the problem is:
1. your add_new_player function, before anothing else, can you simple print out the $_POST data like so:
<?php echo '<pre>'; print_r($_POST); echo '</pre>'; die; ?>
Does all the data look correct?
2. Print out the value of $player_name_title after you have set it’s value. Is that correct?
Apart from that, I’m not sure what the issue could be…
The 1 field being saved is a strange issue and may be related to running out of PHP memory during the save? Perhaps you could even check your server logs for any error reports during the save?
Let me know how you get on.
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users
Helping others is a great way to earn karma, gain badges and help ACF development!
🚀 This week’s session of ACF Chat Fridays dips into the preliminary results of our first ever user survey. Don’t miss it! https://t.co/3UtvQbDwNm pic.twitter.com/kMwhaJTkZc— Advanced Custom Fields (@wp_acf) May 9, 2023
© 2023 Advanced Custom Fields.