Saving custom hook

My Account Forums Plugin Support WP User Frontend Pro Saving custom hook

Viewing 9 posts - 46 through 54 (of 54 total)
  • Author
    Posts
  • #74322
    towhid
    Participant

    Hello,

    Would you please check your site now and let me know the result. The Developer has reconstructed the code.

    Thanks

    #74353
    MareVisie
    Member

    The fields still don't save their values…

    Did The Developer change my code or the plugin's code?

    #74377
    MareVisie
    Member

    Hi Towhid,

    I found out why it wasn't working. I used identical meta_keys to ones already used in the fixed form elements. I'm hugely embarrassed, but now the code works fine. I'm sorry to have wasted so much of your and other's time.

    #74378
    MareVisie
    Member

    Hi Towhid,

    I'm afraid I have cheered to soon. The fields only work on the administrator account, on none of the other accounts they work.

    #74413
    towhid
    Participant

    Hello MareVisie,

    Thanks for the reply!
    Can I see the meta_keys you mentioned? Any screenshot or any other medium is ok.

    Thanks

    #74423
    MareVisie
    Member

    Hi Towhid,

    In Registration Form with ID = 199 using the Edit Profile: [wpuf_profile type="profile" id="199"] I have following fields:

    meta_keys

    As you can see the meta_keys are now edu_programme2 respectively edu_institute2, but they originally were edu_programme and edu_institute. However, the fields added by the action hookeducation-hook still don't save their values. In the code I used the following code:

    
    function update_education_hook( $post_id ) {
        if ( isset( $_POST['education_institute'] ) ) {
            update_post_meta( $post_id, 'edu_institute', $_POST['edu_institute'] );
        }
    }
    add_action( 'wpuf_add_post_after_insert', 'update_education_hook' );
    add_action( 'wpuf_edit_post_after_update', 'update_education_hook' );
    	?>
    

    As you can see I've only added the edu_institute to the update_education_hook function. However, nothing ever gets saved…

    #74425
    MareVisie
    Member

    Here's a storyboard of what's going wrong. As you can clearly see the values don't save after a succesful profile update:




    #74495
    MareVisie
    Member

    Were the screenshots useful? Any updates?

    #74877
    towhid
    Participant

    Hello MareVisie,

    I am really sorry for my late reply!

    I'll reach out my developer team now and follow up you by the sunday morning. Our office will be closed for Durgapuja. We'll be available from Sunday.

    Thanks

Viewing 9 posts - 46 through 54 (of 54 total)
  • The topic ‘Saving custom hook’ is closed to new replies.