Home › Forums › ACF PRO › ACF_FORM() get return › Reply To: ACF_FORM() get return
Hi @triixx
I’m afraid you can’t pass the message from the acf/save_post
hook. What you can do is to create a list of error codes and then use the wp_redirect() function to add the parameters to the URL so it becomes something like this:
http://example.com/register/?success=false&error=1
Then you can check the error code and show it on the front end like this:
if( $_GET['success'] == 'false' && $_GET['error'] = '1' ) {
echo "Error message code 1";
}
If you want, you can also use the cookie to pass the message. This page should give you more idea about it: http://www.w3schools.com/php/php_cookies.asp.
I hope this helps 🙂
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.