Forum Replies Created
-
AuthorPosts
-
Anh Tran
KeymasterHi Sergio,
We haven't had an extension for WooCommerce yet. For now, the MB Frontend Submission might work for WooCommerce (with simple fields like price), but we haven't tested it yet.
Anh Tran
KeymasterHi, we've released a new version for MB User Profile 2 days ago addressing this bug. Please update.
If you're using AIO (which hasn't released a new version yet), please set the
password_strength="weak"in the login shortcode.Anh Tran
KeymasterHi FED,
This is the sanitization mechanism. Please see this blog post for details and the fix.
Anh Tran
KeymasterHi netalys,
You probably need to set attribute
disabledorreadonlyfor the title field. Please see this blog post to know how to create custom settings for post fields.Anh Tran
KeymasterHi Jessica,
Can you please check that if you choose to store custom fields in a custom table? Please go to Settings tab in the MB Builder (I guess you're using it), and scroll to bottom to see if the checkbox for custom table is checked.
And do the fields show up on the back end?
February 29, 2020 at 12:01 AM in reply to: ✅Field conditional logic doesn't work with Gutenberg #18432Anh Tran
KeymasterHi Yumiko,
I found the problem. The
post_typeis not a Meta Box field, so using it the normal way doesn't work. You need to use outside conditions.Change your code to:
add_filter( 'rwmb_meta_boxes', function ( $meta_boxes ) { $prefix = ''; $meta_boxes[] = array ( 'title' => esc_html__( 'test', 'text-domain' ), 'id' => 'test', 'post_types' => array( 0 => 'post', 1 => 'page', 2 => 'general', ), 'context' => 'normal', 'priority' => 'high', 'fields' => array( array ( 'id' => $prefix . 'post_mnfi92e2ko', 'type' => 'post', 'name' => esc_html__( 'Post', 'text-domain' ), 'post_type' => 'page', 'field_type' => 'select_advanced', 'class' => 'your-custom-class', ), ), ); return $meta_boxes; } );Note that I added a
your-custom-classto set a CSS class for your field. And then add the following code to your theme'sfunctions.phpfile (or using a functionality/Code Snippet plugin):add_filter( 'rwmb_outside_conditions', function( $conditions ) { $conditions['.your-custom-class'] = [ 'visible' => ['post_type', 'page'], ]; return $conditions; } );Anh Tran
KeymasterHi,
The
wysiwygeditor uses wp_editor() function to render the editor. So it might use the same hooks as the default editor (I'm not 100% sure about that, this need to be checked and confirmed). You can try disable Gutenberg first, since tinyMCE in Gutenberg is heavily customized and hooks might not work.Anh Tran
KeymasterI see. For
date,timefields, Meta Box uses its own field type. You probably need to create a custom field type to get rid of the overriding from the plugin.Anh Tran
KeymasterHi arkonisus,
Thanks for your feedback. The year 2000 is interesting. I haven't experienced a similar issue. Let me check that and fix the bug.
Anh Tran
KeymasterHi Jefferson,
Can you try re-downloading the plugin from your account page? I think there's some files missing or the download was broken.
February 25, 2020 at 4:29 PM in reply to: ✅How to filter post select field by metabox custom field? #18400Anh Tran
KeymasterHi Rick,
I think that can be done with some code. MB Builder couldn't help building complex queries.
This is a pseudo code that can help you to start with:
You might need to change the query to get the proper characters for you.
Anh Tran
KeymasterHi SIW, it's already supported.
February 25, 2020 at 4:18 PM in reply to: ✅Field conditional logic doesn't work with Gutenberg #18398Anh Tran
KeymasterHi Yumiko,
Thanks a lot for being our customer for years! I really appreciate that and your support!
Regarding this issue: a problem here is you set the meta box to appear to only 2 post types post and general. So, when you set the conditional logic for post type = page, it can't work (because the meta box is not loaded for that post type). Can you please change the
post_typesparameter of the meta box to includepageand try again? I've checked and seen that it supportspost_typerule.February 25, 2020 at 4:12 PM in reply to: ✅Allow editing form data which is submitted by "that" author #18397Anh Tran
KeymasterHi Calpaq,
In the latest version of the plugin, we added a check for permission, that only users with proper capability can edit posts. You can see it with this code:
private function user_can_edit() { if ( empty( $this->config['post_id'] ) ) { return true; } if ( ! is_user_logged_in() ) { return false; } $post = get_post( $this->config['post_id'] ); return $post && ( $post->post_author == get_current_user_id() || current_user_can( 'edit_post', $post->ID ) ); }That means only logged in users which either is the post author or have edit post permission can edit that post. If you allows non-logged in users to edit post, they can simply put any post ID in the URL and thus, can edit any post/page of your site.
Anh Tran
KeymasterHi Jon,
Did you mean creating a custom field "name" for products? If yes, then simply create a meta box with one text field for the
productpost type. Please see this guide to start. -
AuthorPosts