Skip Navigation

[Resolved] save custom field value as a product attribute in woocommerce

This support ticket is created 4 years, 3 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Karachi (GMT+05:00)

Author
Posts
#1771333

Tell us what you are trying to do?
I would like to make a clean interface made with Toolset custom fields to save Woocommerce custom attributes, which I can display in a custom product view.
Is there any documentation that you are following?

Is there a similar example that we can see?

What is the link to your site?

#1772175

Hi,

Thank you for contacting us and I'd be happy to assist.

You can use Toolset Types to add custom fields and custom taxonomies with WooCommerce's "Products" post type and they can also be shown on the custom product views on the front-end.

However, there is no built-in feature available in Toolset which can be used to connect these with the WooCommerce's own custom attributes, which are used for the product variations.

WooCommerce stores them in its own structure, using the combination of custom fields and taxonomies and this connection will require customization.

Here some useful resources to help you get started in the right direction:
https://stackoverflow.com/questions/29549525/create-new-product-attribute-programmatically-in-woocommerce
https://wordpress.stackexchange.com/questions/305461/woocommerce-add-to-simple-product-attribute-programmatically

For more personalized assistance around custom code, you can also consider hiring a professional from our list of recommended contractors:
https://toolset.com/contractors/

regards,
Waqar

#1772179

My issue is resolved now. Thank you!