Forum Replies Created
-
AuthorPosts
-
Long Nguyen
ModeratorHi,
I'm not sure how the script (lightbox) implements its code. Please try to contact the script support to ask for help in this case.
Long Nguyen
ModeratorHi,
After the settings on the settings page saved, the page also reloads so you can use the action hook
mb_settings_page_loadto add some actions after settings have been saved.See more in the documentation https://docs.metabox.io/extensions/mb-settings-page/#hooks.
Long Nguyen
ModeratorHi Martin,
For specific field types such as media fields
file, file_advanced, file_upload, image, image_advanced, image_upload, single_image, you might need to add some extra code to get the field details.$group = rwmb_meta( 'group_id' ); $image_ids = $group['image_key'] ?? : []; foreach ( $image_ids as $image_id ) { $image = RWMB_Image_Field::file_info( $image_id, ['size' => 'thumbnail'] ); echo '<img src="' . $image['url'] . '">'; }See more in the documentation https://docs.metabox.io/extensions/meta-box-group/#sub-field-values.
The code to show images in your case would be:
$disli = $dislider['gallimage'];//array? foreach ( $disli as $value ) { $image = RWMB_Image_Field::file_info( $value, ['size' => 'thumbnail'] ); echo '<img src="' . $image['url'] . '">'; }Long Nguyen
ModeratorHi,
Please follow this documentation to know how to get sub-fields value inside a cloneable group https://docs.metabox.io/extensions/meta-box-group/#getting-sub-field-value.
The code would be:
$array = $dislider['sub_group_btn']; foreach ( $array as $value ) { echo $value['buttontext']; echo '<br>'; }January 23, 2021 at 11:34 AM in reply to: ✅Custom Post Type Label in Frontend Submission Form #24155Long Nguyen
ModeratorHi,
The text is located in the file
/src/Dashboard.phpline 71. But modifying the code directly is not encouraged because it will be removed when updating the plugin.I will create a feature request to support showing the post type on the welcome message.
Thank you.
January 22, 2021 at 10:02 PM in reply to: ✅front end submission dashboard with custom post type #24151Long Nguyen
ModeratorHi,
You can just send this topic to Divi's support and the site information to let them see the conflict. I'm also going to create a feature request for the developer team to create an update to compatible with Divi.
For now, you can use another page builder such as Elementor or Beaver. There are two extensions to integrate Meta Box and that page builders: Meta Box – Beaver Themer Integrator, Meta Box – Elementor Integrator.
January 22, 2021 at 9:52 PM in reply to: ✅Error: There are some errors submitting the form. Please correct and try again #24150Long Nguyen
ModeratorHi Calpaq,
To debug the issue, please follow this topic https://support.metabox.io/topic/how-to-create-a-new-topic/.
If the issue still persists, please do the step Private website info. I will check it out.
Long Nguyen
ModeratorHi,
The helper function rwmb_meta() does not support argument
query_args. Some field types (image, file, etc.) or extension (MB Settings Page, MB Custom Table) support passing the argument.If you want to get the published post only, you should create a new WP_Query and use the helper function inside the loop.
$args = array( 'post_type' => 'post', 'post_status' => 'publish', ); $my_query = new WP_Query( $args ); while( $my_query->have_posts() ) { // Loop in here $my_query->the_post(); $field_value = rwmb_meta( 'field_id', '', get_the_ID() ); }Long Nguyen
ModeratorHi David,
Please go to Admin Dashboard > Settings > Permalinks > Save the current setting permalink (Post name) again to update the permalink for the CPT.
January 22, 2021 at 6:29 AM in reply to: ✅front end submission dashboard with custom post type #24128Long Nguyen
ModeratorHi,
Please see my screen record https://share.getcloudapp.com/yAuZpQEx.
It works with the Block editor as well. You can test again with two pages:
- Post type
post: https://geschenkkartendisplay.de/minis-bearbeiten/ - Post type
mini: https://geschenkkartendisplay.de/minitest/
Long Nguyen
ModeratorHi Martin,
Please go to Admin Dashboard > Meta Box > License > Add the license key to the box and click Save changes to activate the Meta Box license on your site.
January 21, 2021 at 9:44 PM in reply to: ✅front end submission dashboard with custom post type #24123Long Nguyen
ModeratorHi,
Follow the troubleshooting steps on this comment https://support.metabox.io/topic/front-end-submission-dashboard-with-custom-post-type/#post-22718, I've found that if I switch to the default theme of WordPress (Twenty TwentyOne), the frontend dashboard will show the post type correctly. Could you please confirm it?
January 21, 2021 at 6:43 PM in reply to: ✅post type for lawyer profiles as well as connections between other posts #24119Long Nguyen
ModeratorHi,
Yes, it is possible. There is an extension for Meta Box called MB Relationships which helps you to create many-to-many relationships between posts, terms and users in WordPress.
Get more details in the documentation https://docs.metabox.io/extensions/mb-relationships/.
Long Nguyen
ModeratorHi Louise,
Dokan Multivendor is a premium plugin so I've not tested Meta Box with it. Please share a copy of this plugin, take some screenshots of the issue and share the admin site account via this contact form https://metabox.io/contact/. I will check it out.
January 21, 2021 at 11:16 AM in reply to: ✅Image Advanced field "Force delete" option doesn't work #24112Long Nguyen
ModeratorHi,
Actually, after deleting a post, the post meta is still stored in the database. So I think you should:
1. Delete the attachment (image).
2. Delete the post meta.The action hook before_delete_post will help you to achieve the goal.
Refer to this topic: https://wordpress.stackexchange.com/questions/134894/correctly-delete-posts-with-meta-and-attachments
and some WP functions:
https://developer.wordpress.org/reference/functions/wp_delete_attachment/
https://developer.wordpress.org/reference/functions/delete_post_meta/ - Post type
-
AuthorPosts