Cannot Translate
Support › MB User Profile › Cannot TranslateResolved
- This topic has 3 replies, 2 voices, and was last updated 4 years ago by
Long Nguyen.
-
AuthorPosts
-
October 9, 2021 at 12:39 PM #31241
justdoit123
Participantbelow is my MB custom meta for User, i just want to have a form for user to update their account info wordpress.
i paste this code to functions.php, already show up.
But i cannot translate it, it cannot translate, other MB custom field can be translated normally, not this one:
add_filter( 'rwmb_meta_boxes', 'account_info' ); function account_info( $meta_boxes ) { $prefix = ''; $meta_boxes[] = [ 'title' => __( 'Email - Account Password', 'text-domain' ), 'id' => 'account-info', 'type' => 'user', 'fields' => [ [ 'name' => __( 'Email', 'text-domain' ), 'id' => $prefix . 'user_email', 'type' => 'email', 'desc' => __( '', 'text-domain' ), ], [ 'name' => __( 'New Account Password', 'text-domain' ), 'id' => $prefix . 'user_pass', 'type' => 'password', 'label_description' => __( 'Account password, not password for encrypted message', 'text-domain' ), 'desc' => __( 'Enter new password if you want to change', 'text-domain' ), 'placeholder' => __( '', 'text-domain' ), ], [ 'name' => __( 'Your nick name', 'text-domain' ), 'id' => $prefix . 'display_name', 'type' => 'text', ], ], ]; return $meta_boxes; }October 9, 2021 at 10:03 PM #31245Long Nguyen
ModeratorHi,
I do not see any issue when translating the field name to another language. You might need to change the text domain
text-domainto your theme or plugin text domain.Screen record https://share.getcloudapp.com/mXuP8DAm
(using WPML)October 9, 2021 at 10:35 PM #31247justdoit123
Participanthi, yes, i already changed text-domain, i leave it as an example. Do you know any other reason why it cannot be translated ??
only this custome MB cannot be translated
October 10, 2021 at 9:28 AM #31249Long Nguyen
ModeratorHi,
I'm using WPML to translate the custom field label as well. What's the plugin that you use to translate it? Or there is a duplicate meta box with custom field labels.
-
AuthorPosts
- You must be logged in to reply to this topic.