This support ticket is created hace 7 años, 2 meses. 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.
Hoy no hay técnicos de soporte disponibles en el foro Juego de herramientas. Siéntase libre de enviar sus tiques y les daremos trámite tan pronto como estemos disponibles en línea. Gracias por su comprensión.
I am trying to add a select option next to my loop items. I'd like for users to be able to choose one the one they want & then have the details (custom field data) be added to their product in WooCommerce.
Here is the URL where you can see what I'm trying to do: enlace oculto
You have to enter GHE2017 to view the site.
In the Description area, you can choose a date & location. Those details were setup using a custom post type called "Course Dates" that is a child post type of Products.
Once someone selects the date & location they want, how do I add that data their shopping cart? I just need a way to show them on the shopping cart which date & location they chose.
I will also want to add that same information to their confirmation email & their profile, but I hope the same process will work for all 3 instances.
I hope this makes sense. Please let me know if you have any questions or are able to help.
Our Woocommerce Views plugin is not able to modify the Checkout and Cart page templates.
You are only able to modify your Shop and product pages with woocommerce views.
So if you want to modify your Checkout and Cart pages you will need to modify the woocommerce php templates for these pages.
Thank you for the reply & info. I would use their Variables add-on except that I need to be able to make the Variable into child posts of another post type (called Courses). I’m using the LearnDash plugin & trying to find a way to create live courses with multiple dates & locations. It’s surprisingly more complicated than I anticipated. Seems like something a lot of people would want to do.
Anyway, I’ll look into the WooCommerce files or see if there’s a way to create a plugin that automatically inserts the Types fields into the cart for me.
How do I display the "selected" option on the front-end?
==> You can display any custom field by creating a Content Template for the products. And you may also want to use WooCommerce Views to add various WC options / shortcodes in the content template:
I would suggest to put your dropdown options as a custom field outside of description, like any other custom field attached to the product / post. Because the description is not submitted when we add a product to the cart.