Support Forum ยป User Profile

Forum Replies Created

Viewing 15 posts - 61 through 75 (of 115 total)
  • Author
    Posts
  • in reply to: File/image input field does not work when in group #6753
    Truong GiangTruong Giang
    Participant

    Hi there,

    Sorry about this. There are some problems so we can't send you the hotfix. You can use image_advanced field and add upload_files capability for users. The code below add that cap for subscriber:

    
    /**
     * Allow the media uploader work on specific pages
     */
    function mb_allow_contributor_uploads() {
    	if ( is_admin() ) {
    		return;
    	}
    	$path = isset( $_SERVER['REQUEST_URI'] ) ? $_SERVER['REQUEST_URI'] : '';
    	if ( ! $path || '/page-slug' != $path ) {
    		return;
    	}
    	/**
    	 * Replace 'subscriber' with the required role to update, can also be contributor
    	 */
    	$subscriber = get_role( 'subscriber' );
    	// This is the only cap needed to upload files.
    	$subscriber->add_cap( 'upload_files' );
    }
    add_action( 'init', 'mb_allow_contributor_uploads' );
    
    in reply to: File/image input field does not work when in group #6750
    Truong GiangTruong Giang
    Participant

    Hi there,

    Can you give me your email address? I will give you a quick fix version. This version works if the image field is in level 1 of group (like your case).

    Thank you.

    in reply to: Applying class to output #6729
    Truong GiangTruong Giang
    Participant

    Hi there,
    You can use something like this:

    
    <div class="anyclass">
        [rwmb_meta meta_key="text_6" type="text"]
    </div>
    
    in reply to: Taxonomy Advanced Values not saving correctly #6728
    Truong GiangTruong Giang
    Participant

    Hi there,

    Can you give me the code you use to register meta box?

    in reply to: Error when creating Taxonomy #6708
    Truong GiangTruong Giang
    Participant

    Which version of MB Custom Post Type are you using? I tried your scenario but it works. Can you share your credential for us to check it? If you can, please send the WordPress admin credential to [email protected]

    Thank you very much.

    UPDATE: Sorry. I got the problem. Please wait for me to fix it.

    in reply to: File/image input field does not work when in group #6700
    Truong GiangTruong Giang
    Participant

    Hi,

    I got the problem. We are fixing it ASAP.

    Thank you.

    in reply to: Error when creating Taxonomy #6699
    Truong GiangTruong Giang
    Participant

    Hi there,

    Do you use latest version of MB Custom Post Type? There is something wrong here. It's should be add_action( 'init', 'your_prefix_register_taxonomy', 0 ); instead of add_action( 'init', 'your_prefix_register_taxonomy');

    I used the code you give but I didn't see any errors.

    in reply to: Validation does not work for fields in group #6686
    Truong GiangTruong Giang
    Participant

    Hi,

    Thank you for your report. We will consider this problem in the future. ID of field in clonable group is dynamic, so we can't use old mechanism. This is a hard part.

    Thank you very much.

    in reply to: Hyperlink URL with meta box shortcode #6684
    Truong GiangTruong Giang
    Participant

    Oh so sorry, I have a mistake. Please try the code below:

    <a href='[rwmb_meta meta_key="url_1"]'>[rwmb_meta meta_key="url_1"]</a>

    And you should switch the editor to text mode instead of visual mode.

    in reply to: Hyperlink URL with meta box shortcode #6673
    Truong GiangTruong Giang
    Participant

    Hi,

    You can insert this to widget:
    <a href="[rwmb_meta meta_key="url_1" ]">[rwmb_meta meta_key="url_1" ]</a>

    Thank you.

    in reply to: Validation does not work for fields in group #6672
    Truong GiangTruong Giang
    Participant

    Hi,

    Sorry because current version of MB Group only supports HTML5 validation via attributes when clone. Please use it if possible.

    Thanks.

    in reply to: Hyperlink URL with meta box shortcode #6669
    Truong GiangTruong Giang
    Participant

    Hi there,

    Do you means https://metabox.io/ instead of https://metabox.io/?

    You can use this code: echo make_clickable( do_shortcode( '[rwmb_meta meta_key="url_1" ]' ) );

    Thank you.

    in reply to: meta-box-yoast-seo #6653
    Truong GiangTruong Giang
    Participant

    Hi there,

    You can add it to field config array which you want to use Yoast Seo functionality:

    
        $meta_boxes[] = array(
            'title'      => __( 'Test Meta Box', 'textdomain' ),
            'post_types' => 'post',
            'fields'     => array(
                array(
                    'id'   => 'name',
                    'name' => __( 'Name', 'textdomain' ),
                    'type' => 'text',
                    'add_to_wpseo_analysis' => true,
                ),
                array(
                    'id'      => 'gender',
                    'name'    => __( 'Gender', 'textdomain' ),
                    'type'    => 'radio',
                    'options' => array(
                        'm' => __( 'Male', 'textdomain' ),
                        'f' => __( 'Female', 'textdomain' ),
                    ),
                ),
                array(
                    'id'   => 'email',
                    'name' => __( 'Email', 'textdomain' ),
                    'type' => 'email',
                ),
                array(
                    'id'   => 'bio',
                    'name' => __( 'Biography', 'textdomain' ),
                    'type' => 'textarea',
                ),
            ),
        );
    
    in reply to: Image upload does not work with MB Frontend Submission #6641
    Truong GiangTruong Giang
    Participant

    We will discuss in the topic: https://support.metabox.io/topic/fileimage-input-field-does-not-work-when-in-group/

    I'll close this topic.

    in reply to: File/image input field does not work when in group #6639
    Truong GiangTruong Giang
    Participant

    Hi,

    Can you give me your email? I'll send you the fixed code. We still have some works with MB Group so we will update it later.
    Please make sure that you are using MB Group 1.2.10 before use fixed code.

    UPDATE: We have just released MB Group 1.2.11. Please update it.

    Thanks.

Viewing 15 posts - 61 through 75 (of 115 total)