Hello, I need help. It seemed an easy task but for some strange reason, it's not working as you explained on this page - https://docs.metabox.io/custom-fields/
I created a custom field (Text Input) named Tagline which will be displayed underneath the title of the product name - https://share.getcloudapp.com/4gueRZ7O
Text Input is visible on the product page and I inserted a word - https://share.getcloudapp.com/L1u98WYX
I created a view for this but the tagline is not being displayed on the front end - https://share.getcloudapp.com/P8u7D6lw
Please help me to get it done. Thank you
Meta Box extensions are not fully compatible with WooCommerce, it looks like they use some specific functions to call the template and their field value on the frontend. In this case, I recommend using WooCommerce hooks to display the field value. Please read more on this article https://metabox.io/add-custom-fields-for-woocommerce/
Hello Long Nguyen, Thanks for your prompt reply. Following the solution provided on your given link, I was able to display the Value of a custom field on the front end but how can I display the value in the exact location where it should be?
In my case, I want to display a subtitle underneath the product title (Not in the short description area). In the filed setting I am choosing the option - After post title
But the value is not being displayed underneath the title.
I am entering the hook using a snippet plugin. Help me out when you get a chance. Thank you.
You can find the supported hooks on the product page here https://www.businessbloomer.com/woocommerce-visual-hook-guide-single-product-page/
or contact WooCommerce support to ask for a hook to display the field value on the product page.
Hello Long, Thank you for your reply.
I was wondering where the data inserted using the custom field is saved in the database.
Is it a good idea to create a separate database for every custom field using this option - Save data in a custom table?
By the way, I've already checked out this documentation - https://metabox.io/plugins/mb-custom-table/
I am confused by this sentence - This reduces the number of rows in the database which can cause a performance issue when the data grows.
Could you please clarify this?
If I plan to have 20,000+ products with a few custom fields enabled, will it be a good decision to use a Custom table instead of the default table?
Performance is very important so please suggest to me the best option to follow. Thank you
Yes, you can use the extension MB Custom Table to save field value in a custom table, not save value to the standard table of WordPress (wp_postmeta). In the default table
wp_postmeta, one post can have, for example, 20 custom fields associated, which means there are 20 rows multiple with the number of posts on your site.
Using the custom table, one post can have only one row. The custom fields are columns and save value to the cell as you can see on the documentation https://docs.metabox.io/extensions/mb-custom-table/
And read more the example here https://metabox.io/plugins/mb-custom-table