Forum Replies Created
-
AuthorPosts
-
Long Nguyen
ModeratorHi Robert,
You need to add the parameter
idand use the parameteroption_namewith the name in lowercase and underscore, with no space and special characters.Please read more on the documentation https://docs.metabox.io/extensions/mb-settings-page/#using-code
Long Nguyen
ModeratorHi Robert,
Can you please share the code that creates the settings page on your site?
November 8, 2021 at 12:30 PM in reply to: ✅Creating a custom field with value from other custom fields #31796Long Nguyen
ModeratorHi,
It is possible. You can use Meta Box's action hooks like
rwmb_{$meta_box_id}_after_save_postto update a field value from another custom field after saving the post.Please get more details on the documentation
https://docs.metabox.io/actions/#rwmb_after_save_post
https://docs.metabox.io/rwmb-set-meta/Long Nguyen
ModeratorHi,
Please try to deactivate all plugins except Meta Box, MB AIO and switch to the standard theme of WordPress then re-check the issue.
And check the tab Console of the inspect tool if there is a JS error https://developer.chrome.com/docs/devtools/open/
Long Nguyen
ModeratorHi,
Because we've received a lot of feature requests and reporting issues so I do not have the estimated time for this question. The development team is working tirelessly to create the integration but it will take time to do that. Thanks for your patience.
Long Nguyen
ModeratorHi,
Thanks for the feedback.
I'm going to inform the developer team to consider adding it to the to-do list for the future development of the plugin.
November 7, 2021 at 10:32 AM in reply to: ✅WordPress database (MariaDB) error in SQL syntax - MB Relationships #31781Long Nguyen
ModeratorHi,
Can you please share the code that you use to get the relation posts? And MariaDB version on your server?
Long Nguyen
ModeratorHi,
You can follow these topics to update the post title by custom field value with the meta box hook rwmb_{$meta_box_id}_after_save_post
https://support.metabox.io/topic/adding-metabox-field-data-to-the-post-title/
https://support.metabox.io/topic/trying-to-set-title-from-field-in-cpt-from-the-custom-fields/Long Nguyen
ModeratorHi,
Can you please share the code that creates the CPT on your site? I will implement it on my end to check the issue.
You can also enable the debug log to check if there is an error message after updating MB AIO to the new version 1.15.2
https://codex.wordpress.org/WP_DEBUGNovember 6, 2021 at 8:49 PM in reply to: Fields - Posts are publishing even if 'Required' is true #31774Long Nguyen
ModeratorHi,
The field in the inactive tab will be considered as a hidden field so it will not be validated. It is expected behavior. However, I will inform the development team to consider covering this case.
Long Nguyen
ModeratorHi,
You can follow this article to create a
single_imagefield and update the image to the user avatar.
https://metabox.io/create-custom-avatar/Then you can add the meta box ID to the frontend shortcode to allow users to update their avatar on the frontend. Read more on this documentation https://docs.metabox.io/extensions/mb-user-profile/#edit-profile-form
Long Nguyen
ModeratorHi,
I've tested to bundle Meta Box and MB AIO in a custom plugin but do not see any issue like that. Here is the content of the file composer.json
{ "repositories":[ { "type": "composer", "url": "https://wpackagist.org" }, { "type": "composer", "url": "https://packages.metabox.io/2484d090029feaab8ce106de5e693400" } ], "require": { "wpackagist-plugin/meta-box": "dev-trunk", "meta-box/meta-box-aio": "dev-master", "composer/installers": "^1" }, "extra": { "installer-paths": { "vendor/meta-box/meta-box": ["wpackagist-plugin/meta-box"], "vendor/meta-box/{$name}/": ["type:wordpress-plugin"] } }, "autoload": { "files": [ "vendor/meta-box/meta-box/meta-box.php", "vendor/meta-box/meta-box-aio/meta-box-aio.php" ] } }You can also hook to the action
tgmpa_registerto remove the notice text. Find it in the file/meta-box-aio/src/Plugin.phpNovember 6, 2021 at 6:47 PM in reply to: ✅PHP Block generated from Builder not rendering in editor or front end. #31771Long Nguyen
ModeratorHi,
You can export field groups then import them to other sites, please get more details on this documentation https://docs.metabox.io/extensions/meta-box-builder/#export--import
Long Nguyen
ModeratorHi,
Because in the Quick Edit mode or Bulk Edit, the global variable
$_POSTdoes not store any value. You can move the variable$datainside theifcondition to make sure the global variable stores value. For example:function set_leasing_meta_title( $data , $postarr ) { if($data['post_type'] == 'leasing') { if($_POST['type_of_leasing'] == 'Shop Spaces') { $title = $_POST['shop_station'] . ' ' . $_POST['shop_unit']; $post_slug = sanitize_title_with_dashes ($title,'','save'); $post_slugsan = sanitize_title($post_slug); $data['post_title'] = $title; $data['post_name'] = $post_slugsan; } } return $data; }November 5, 2021 at 8:33 PM in reply to: ✅PHP Block generated from Builder not rendering in editor or front end. #31755Long Nguyen
ModeratorHi,
The feature Get PHP Code of the builder does not support converting Twig code to PHP code. So you have to change the parameter
render_codetorender_callbackorrender_templateand change the code to PHP code to render elements on the frontend. Please read more on the documentation https://docs.metabox.io/extensions/mb-blocks/#render_callback -
AuthorPosts