Support Forum » User Profile

Forum Replies Created

Viewing 15 posts - 3,811 through 3,825 (of 3,835 total)
  • Author
    Posts
  • PeterPeter
    Moderator

    Thanks for sharing the info.

    The attribute lock does not look supported when registering the custom block. I will inform the development team to consider supporting this feature in future updates.

    PeterPeter
    Moderator

    Hello,

    Can you please reinstall this plugin and recheck the issue? And share the server info by going to admin area > Tools > Site Health > Info tab > Server.

    PeterPeter
    Moderator

    Hello Denise,

    When registering the meta box and custom fields, you can get the user name with your code and set the default value with the name. For example:

    add_filter( 'rwmb_meta_boxes', function ( $meta_boxes ) {
        // your code to get the current user name here
        $user_name = 'Default user name';
    
        $meta_boxes[] = [
            ...
            'fields'     => [
                [
                    'name' => 'User Name',
                    'id'   => 'user_name',
                    'type' => 'text',
                    'std' => $user_name
                ],
            ],
        ];
    
        return $meta_boxes;
    } );

    Read more on the documentation https://docs.metabox.io/creating-fields-with-code/#field-settings

    in reply to: Open Street Map and Bricks. Code r doesn't work #38985
    PeterPeter
    Moderator

    Hello there,

    @Shemzone: can you please add the code to a template file of a theme and recheck the issue? I think there is a compatibility issue when executing the code in the Bricks builder.

    @Dan: please create another topic and post your issue there. Make sure that you have the latest version of all extensions on your site. If you are using Google Map field, the issue mostly relates to the validity of your API key.

    in reply to: Refund request #38984
    PeterPeter
    Moderator

    Hello Bilal,

    Please contact us here https://metabox.io/contact/
    our team will help you to process the request.

    in reply to: invalid form submission #38983
    PeterPeter
    Moderator

    There is no issue when I test to create a new user from the registration form on your site. So let's check this again and let me know if the issue still happens.

    in reply to: Saving CPT with featured image not possible #38967
    PeterPeter
    Moderator

    Hello Stefan

    It is not possible to replace the featured image of the post if you save the custom field value to the custom table. Because the featured image of the post has the ID _thumbnail_id and save value to the default table of WordPress wp_postmeta.

    You can save the field value to the default table instead of the custom table and see if it works.

    in reply to: How would i set this hierarchy up #38966
    PeterPeter
    Moderator

    Hello spip,

    When registering a custom post type, you can enable the option Hierarchical to make the post hierarchically and set a post as a child of another post like that. Please read more here register_post_type

    For connecting two posts of two post types, you can use the extension MB Relationships. (Coaching - Organisational

    Regarding the post slug or URL, you also need to use a custom code to customize the slug on your own but it would need to have more complicated code. You can also read more here https://wordpress.stackexchange.com/questions/41988/redeclare-change-slug-of-a-plugins-custom-post-type

    in reply to: iOS media browser scrolls to top of page when closing #38965
    PeterPeter
    Moderator

    Hello Glen

    Unfortunately, our development team has taken a look at this issue but still not had a solution to resolve this. So I will leave this topic as Open status if there are others here who will chime in with better answers and can advise us to help you. Sorry for not being helpful in this case.

    in reply to: Hiding default editor (Gutenberg or not) #38961
    PeterPeter
    Moderator

    You can use this PHP code to get the post ID and create a condition to check it before removing the editor.

    $post_id = null;
    if ( isset( $_GET['post'] ) ) {
        $post_id = intval( $_GET['post'] );
    } elseif ( isset( $_POST['post_ID'] ) ) {
        $post_id = intval( $_POST['post_ID'] );
    }

    the correct code will look like

    // Remove the editor for a specific post. Change 'post' to your custom post type.
    add_action( 'init', function () {
        $post_id = null;
        if ( isset( $_GET['post'] ) ) {
            $post_id = intval( $_GET['post'] );
        } elseif ( isset( $_POST['post_ID'] ) ) {
            $post_id = intval( $_POST['post_ID'] );
        }
        if( $post_id == 1 ) {
            remove_post_type_support( 'post', 'editor' );    
        }
    } );
    in reply to: invalid form submission #38960
    PeterPeter
    Moderator

    Hello there,

    If it is possible, please share the code that registered the field group with ID campos-usuario. Or share your site credentials by submitting a ticket on this contact form https://metabox.io/contact/.

    in reply to: display relationships to each post in list of cpt #38958
    PeterPeter
    Moderator

    You can check the relationship ID and from, to side when you create the relationship. Please share some screenshots of the relationship, I will help you to find them.

    in reply to: Images are note being displayed from Custom Table #38957
    PeterPeter
    Moderator

    Hello Md Wasim,

    I will take care of this topic from now. On the archive page, you can use the WordPress function get_queried_object_id() to get the term ID and pass it to the helper function rwmb_meta() as you do above.

    $term_id = get_queried_object_id()
    $image_id = rwmb_meta( 'author_single_image', $args, $term_id );
    PeterPeter
    Moderator

    Hello Jacob,

    It looks like you want to add one instance of MB test block on a post/page and allow other blocks added. Please use the setting supports with multiple set to false.

    'supports' => [
        // Use the block just once per post
        multiple: false,
    ],
    in reply to: do_shortcode returns nothing in AJAX call #38950
    PeterPeter
    Moderator

    Hello there,

    It is not possible to render the frontend shortcode via AJAX call because the CSS and JS files will not be loaded along with the HTML code. Please use the shortcode on the page load only to make the shortcode render correctly.

Viewing 15 posts - 3,811 through 3,825 (of 3,835 total)