Home › Forums › Add-ons › Repeater Field › Add Repeater entries from front end with GF › Reply To: Add Repeater entries from front end with GF
Hi Elliot,
Thanks a lot for following this issue I was having, and many other you helped me to address 🙂
I ended solving this with a gravity forms hook (to stick to gf). The hook is very simple and I’m posting just in case someone else might find it helpful.
add_action("gform_after_submission_5", "acf_post_submission", 10, 2);
function acf_post_submission ($entry, $form)
{
$field_key = 'field_52fae7b9b229c';
$post_id = $entry["post_id"];
$value = get_field($field_key, $post_id);
$value[] = array('app_id' => $entry[3],'app_cover' => $entry[2]);
update_field($field_key, $value, $post_id);
}
The only issue I’m trying to solve now is to write a script to don’t let the same user ID submit this form if it already submitted. I’m using the same form (ID->5) for all job posts, so I have to set no duplication for that post id only and allow if it’s a different id, but that’s more a question for gravity forms guys.
Anyways if you have any idea, I will appreciate that you share it with me.
Thanks for all.
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!
We use cookies to offer you a better browsing experience, analyze site traffic and personalize content. Read about how we use cookies and how you can control them in our Privacy Policy. If you continue to use this site, you consent to our use of cookies.