Support Forum ยป User Profile

Forum Replies Created

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • in reply to: โœ…Filter "rwmb_{$field_type}_value" doesn't work #33936
    AharonAharon
    Participant

    Thanks, it's working ๐Ÿ™‚

    in reply to: โœ…Custom Tables along with Show Hide extension #31993
    AharonAharon
    Participant

    Hi Long,
    Thank you for your answer.

    I managed to solve the issue indeed with the Include Exclude extension, using the custom callback: I'm showing all the meta boxes when it's the 'post-new.php' page, and after saving it's showing only one of the meta boxes based on the user's choice. And of course, it doesn't make redundant rows in the other tables ๐Ÿ™‚

    That's how my custom callback looks like:

    public static function include_meta_box( $meta_box ) {
        global $pagenow;
    
        $type_selected = absint( $_POST['type'] ?? 0 );
    
        return 'post-new.php' === $pagenow || $type_selected === $meta_box['include']['type'];
    }
Viewing 2 posts - 1 through 2 (of 2 total)