[Resolved] Custom field for Woocommerce Variations and display it with Views
This support ticket is created 7 years, 11 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.
No supporters are available to work today on Toolset forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.
1) In WooCommerce I use 'variable products' and I would like to add a custom field not on product level but on variations level. Is this possible with Types? If you don't know what I mean please look at the first image of this article where it's explained how to do it the manual way: hidden link. If this is not yet possible with Types, I will follow the steps explained in that article. But can you then add it as feature request for types?
2) When I managed to add that custom field for variations, I ofcourse want to display it in the frontend of my website with Views. I want to output that custom field in the [wpv-woo-product-price] area. See image I uploaded. I believe the shortcode [wpv-woo-product-price] is doing nothing more then 'copy' the standard behaviour of WooCommerce, but can you help me out how to edit that output so that a custom fields can be displayed as well, thanks!
Unfortunately, WooCommerce variation fields can't be created with Types, because those require a custom and special way to take care, while Types works around WP's general standards. You will have to add those via the code (or manual way as your reference link describes).
Using WooCommerce Views you should be able to display these variations, just like the others are shown (if these are added correctly in the system).
However, if WooCommerce Views doesn't help, you can use custom code from hidden link - you can create a short code of this, so the short code can be used in your view.