Reply To: Revive deleted string


Home Forums Front End PM PRO Revive deleted string Reply To: Revive deleted string

#6463
shamim
Keymaster

Please use following


    add_action('save_post', 'undelete_thread');
    function undelete_thread($post_id) {
        $post = get_post($post_id);
        if ($post->post_type == 'fep_message' && $post->post_parent){
            $participants = fep_get_participants( $post->ID );
            foreach( $participants as $participant )        
            {
                delete_post_meta($post->post_parent,'_fep_delete_by_'. $participant );    
            }
        }
    }