Autocomplete fields

Support MB Frontend Submission Autocomplete fields

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #28951
    Infolu OfficialInfolu Official
    Participant

    Hi guys, I have a post type that by the admin area some fields are automatically completed with information, now I'm using mb frontend submission and I need to complete these fields with information how can I do this?

    $form = '[mb_frontend_form post_type="talk" id="talk_mb_info"]';
    echo do_shortcode( $form );
    
    #28966
    Long NguyenLong Nguyen
    Moderator

    Hi,

    Can you please clarify the question? I do not understand it clearly.

    If a field works in the backend, it also works in the form on the frontend.

    #28969
    Infolu OfficialInfolu Official
    Participant

    Hi Long, what I need is that when I save a form the field I specify is automatically filled in, for example

    On my site page there is a function that captures the ip of the visitor I want that when I click on save form from mb frontend , this information is saved in a metatag of my post

    Today in my back-end when I go to my post-type and register a new post when saving I have fields that automatically save information.

    #28971
    Infolu OfficialInfolu Official
    Participant

    In other words, I have hidden fields in this post type, which information must be inserted when saving the mb frontend form.

    #28981
    Long NguyenLong Nguyen
    Moderator

    Hi,

    I think you can use the action hook rwmb_frontend_after_process to update the field value after submitting the form.

    Use the function update_post_meta() to update the field value and refer to this documentation https://docs.metabox.io/extensions/mb-frontend-submission/#form-actions

Viewing 5 posts - 1 through 5 (of 5 total)
  • You must be logged in to reply to this topic.