Support

Account

Home Forums ACF PRO updated_message not working

Solved

updated_message not working

    • marty14

    • November 17, 2017 at 1:59 am

    Upon submitting the front-end form, the confirmation message, as defined by updated_message, is not displayed. The post is actually submitted, but the form is just emptied and re-rendered without a confirmation message that the update/submit was successful. Is there an error in my code below? How can I make the confirmation message pop-up upon submitting?

    <form id='post' class='acf-form' action='' method='post'>
    <?php
      acf_form([
        'field_groups' => ['group_xxx'],
        'post_id'	=> 'new_post',
        'post_title'	=> false,
        'post_content'	=> false,
        'updated_message' => __("Thank you! ...", 'acf'),
        'submit_value' => __("Submit", 'acf'), 
        'form' => false
      ]);
      if(current_user_can('activate_plugins')) {
        acf_form([
          'field_groups' => ['group_yyy'],
          'post_id' => 'new_post',
          'form' => false
        ]);
      }
    ?>
    <div class="acf-form-submit">
      <input type="submit" class="acf-button button button-primary button-large" value="Submit resource suggestion">
      <span class="acf-spinner"></span>
    </div>
    </form>

    Update: In the inspector I just found out that display is still set to none for the confirmation message. How come? What am I doing wrong?

    Screenshot inspector

  • the updated message only gets displayed if the URL parameter ‘?updated=true’ is returned

    Unfortunately the ‘return’ parameter for the form doesn’t do that on default, even if it says so in the documentation 😉

    • udarts

    • August 13, 2019 at 8:38 pm

    I know this is an old thread, but I have the same issue with the latest version.
    The url contains ?updated=true but the message is never shown.

    • udarts

    • August 14, 2019 at 1:07 am

    Never mind, it was a css style that was hiding the message.

Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.

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 Cookie Policy. If you continue to use this site, you consent to our use of cookies.