Support Forum » User Profile

Forum Replies Created

Viewing 15 posts - 451 through 465 (of 3,708 total)
  • Author
    Posts
  • in reply to: Blank page on Add/Edit Custom Post Type #17717
    Anh TranAnh Tran
    Keymaster

    Hi Matt,

    I guess the type taxonomy is used somewhere else on your website. Maybe it's registered by WP or other plugin. In this case, I think you did best: changing its slug makes it unique and works.

    in reply to: Want a Custom Profile Avatar #17716
    Anh TranAnh Tran
    Keymaster

    Hi Nicole,

    You need to get the user ID first, and then use the helper function to get the image. This is a sample code you can start with:

    $user_id = get_current_user_id();
    $images = rwmb_meta( 'support-agent-profile', ['object_type' => 'user'], $user_id );
    $image = $images[0];
    echo "<img src='{$image['url'}'>";

    You might want to change the code to get user ID if that's not the current user.

    in reply to: MB Custom Table And Gravity Forms #17715
    Anh TranAnh Tran
    Keymaster

    Hi,

    #1. That can be done with GF hooks (after creating form) and MB Custom Table API. Something like

    add_action( 'gf_after_create_form', function() {
        $fields = gf_get_form_fields();
        $columns = [];
        foreach ( $fields as $field ) {
            $columns[$field] = 'TEXT NOT NULL';
        }
        MB_Custom_Table_API::create( 'my_custom_table', $columns );
    } );

    Please note that the GF action name and function should be corrected according to GF docs. This is just the pseudo-code, not an actual running code.

    #2. Similar to that, you should hook to GF after submission to insert a new row into the DB. We don't have a public API for that, but you can use $wpdb->insert() to do it.

    in reply to: MB Blocks with allowed_block_types #17714
    Anh TranAnh Tran
    Keymaster

    Hi,

    Each block registered with MB Blocks has an unique ID of meta-box/{$id}. So you can use it to add to your filter list.

    in reply to: Associate two different page types #17713
    Anh TranAnh Tran
    Keymaster

    Hi Matt,

    You can use the MB Relationships to create relationships between 2 post types.

    To output the connections on the front end, you need to use some code. Please see MB Relationships documentation to do that.

    in reply to: Single metabox on Reciprocal Relationship #17712
    Anh TranAnh Tran
    Keymaster

    When you use reciprocal relationships, the "from" and "to" don't matter anymore. So you can use WP_Query on the front end for either side and it will work.

    When saving into the database, the plugin will delete existing connections first, then re-add new connections. It doesn't care about the "from" or "to" side. That's why you see it flips.

    in reply to: Don't hijack bulk activation #17711
    Anh TranAnh Tran
    Keymaster

    Hi Austin,

    The version 5.2.4 already fixed it. Can you please try again?

    in reply to: font awesome select field help #17710
    Anh TranAnh Tran
    Keymaster

    Hi,

    We don't have a field for icon picker yet. I think the best way to do that is creating a new field type. It gives you more flexibility to control the data you want. Using select_advanced might be limited.

    in reply to: Metabox Group Subfields not Showing on Elementor #17709
    Anh TranAnh Tran
    Keymaster

    Hi Florian,

    Unfortunately, we haven't done this yet. There are some technical challenges that we haven't resolved yet.

    in reply to: Prevent Copy Paste From Wysiwyg Editor #17696
    Anh TranAnh Tran
    Keymaster

    Sorry, I should have made it clearer: there is NO such solution for your problem.

    in reply to: Prevent Copy Paste From Wysiwyg Editor #17677
    Anh TranAnh Tran
    Keymaster

    Maybe you should try textarea field with 'readonly' => true. There's no settings for preventing copy & paste for the editor, as far as I know.

    in reply to: Blank page on Add/Edit Custom Post Type #17673
    Anh TranAnh Tran
    Keymaster

    Hi Matt,

    Looks like there's an error with the taxonomy setup and REST API. However, I couldn't replicate it on my local site. Can you take a screenshot of taxonomy settings?

    in reply to: How To Add Style Attribute to Any Input field #17672
    Anh TranAnh Tran
    Keymaster

    Please see custom attributes docs.

    in reply to: Prevent Copy Paste From Wysiwyg Editor #17671
    Anh TranAnh Tran
    Keymaster

    I'm afraid it's not possible. You can't prevent copy & paste in the default WP editor, right?

    in reply to: User Profile and display_name #17670
    Anh TranAnh Tran
    Keymaster

    Hi pza, sorry for the delay. At the moment, it's not possible yet, because display_name is not a custom user meta. It's a field in the users table. I'll update the plugin to support it and all user fields.

Viewing 15 posts - 451 through 465 (of 3,708 total)