Forum Replies Created
-
AuthorPosts
-
Long Nguyen
ModeratorHi,
Yes, you can query to get posts then get the field value associated with the post by post ID
rwmb_meta( 'field_id', '', $post_id );Long Nguyen
ModeratorHi,
Please note that the article with the code above helps you to move the custom field value from the default table
wp_postmetato the custom table. That means the field value exists in the database.Another way, you can create a service request here https://metabox.io/contact/. Our developers will check it, estimate the job and get back to you with a quote.
Long Nguyen
ModeratorHi Cees,
Can you please test to save the custom field value to the custom table when creating/updating a post in the admin area to make sure it works properly?
Long Nguyen
ModeratorHi Stephen,
You can create a custom function to check the field value through remote validation. Refer to the documentation https://docs.metabox.io/validation/#using-code-1
and this topic https://support.metabox.io/topic/remote-validation-example/#post-22957Long Nguyen
ModeratorHi,
There is an option to render with Template file (above Code) to load the external template. Please read more on the documentation https://docs.metabox.io/extensions/mb-blocks/#render_template
Long Nguyen
ModeratorHi Aaron,
Thanks for your feedback.
The render code area works like the MB Views so we have not had the documentation about this section. And yes, you can write Twig code in this area. Some variables supported are listed below it.
Long Nguyen
ModeratorResolved.
The problem happens due to there are two custom fields that have the same ID on a page.
Long Nguyen
ModeratorHi,
You can just add the separator after the closing tag
</a><a href="<?php echo $file['url']; ?>" target="_blank"><?php echo $file['name']; ?></a>,Long Nguyen
ModeratorHi,
Thanks for your feedback.
I've escalated this issue to the development team to fix it in the next update.
Long Nguyen
ModeratorHi Robert,
To export and import custom tables, simply, you can access your database with the PHPMyAdmin tool then use its options to export and import table.
Or follow this article to export/import by coding https://code.tutsplus.com/tutorials/custom-database-tables-exporting-data--wp-28796
Meta Box just helps you to create custom tables and save field values to that, there is no native feature to export/import custom tables.
April 13, 2022 at 6:45 AM in reply to: Add the field on the Metabox Custom Field but not Saved #35601Long Nguyen
ModeratorHi,
You can try to follow this tutorial to increase the PHP setting
max_input_varsto fix the issue
https://metabox.io/wordpress-custom-fields-not-saving-increase-max-input-vars/Let me know how it goes.
Long Nguyen
ModeratorHi Martin,
To display the date field in another language, please enable the setting
timestamp, change the site language in Settings > General.Then use the WordPress function date_i18n() to display the date in localized format.
$value = rwmb_meta( $field_id ); echo date_i18n( 'F j, Y', $value );Refer to this topic https://support.metabox.io/topic/problem-displaying-images-videos-and-date-format-in-french/
In case of using Oxygen builder, you need to contact Oxygen support to ask to implement the code.
Long Nguyen
ModeratorHi,
You can access the database, find them in the table
wp_postsand check the columnpost_type. Then you can change the post type slug with the new one.Or create a CPT with the old slug, then use this plugin to change post type https://wordpress.org/plugins/post-type-switcher/
April 12, 2022 at 10:53 PM in reply to: Problem displaying images, videos and date format in French #35595Long Nguyen
ModeratorHi,
1. Please check this screen record to see how it works on my site https://monosnap.com/file/uLHnzBcBw4pW54cFizPAKpZ551Uf1d
I think you are missing the closing and opening PHP tags in the snippet code and pass the current post ID to the help function if you want to get the field value in the header.add_action( 'wp_head', function () { ?> <script> <?php /* write your JavaScript code here */ $value = rwmb_meta( 'debut_date', '', get_queried_object_id() ); echo date_i18n( 'j F Y', $value ); ?> </script> <?php } );2. I will check this issue and get back to you later.
3. Do you mean to add the custom fields to the field group builder?
Long Nguyen
ModeratorHi,
If you use the frontend submission form to submit posts with the group field, the group and subfield values are associated with the post, not the user. And it is the custom code so you can output the value in any format you want.
-
AuthorPosts