I'm working on a website where we use Woocommerce. I'm using the free version of Toolset.
With each product it's possible to upload mp3 files as samples. This works. This is the upload-sample-file slug (see screenshot 2). The way the code is built, show that it works on the frontend (cart.php).
I've made a second 'custom type' called 'Video Samples'.
How do I make this second custom type visible in php, showing on cart.php? And how do i say to it that is has to behave as an individual custom type for each product in woocommerce?
1. And how do i say to it that is has to behave as an individual custom type for each product in woocommerce?
==> The “Video Samples” custom post type, if you have created using Toolset Types then it should be visible on the backend as individual custom type.
2. How do I make this second custom type visible in php, showing on cart.php?
==> For this please explain a bit more, I am not getting what you are trying to achieve here. Do you want to show custom fields on cart.php or you want to show Posts on cart.php or something else?
1. I've seen it's visible on the backend with each backend product-edit page. Thanks!
2. Yes i want to show the custom fields on cart.php. The information what i fill in in the custom fields 'Video Samples', is what i want to show. So that will be some video's.
Because the custom type 'mp3' is working, i need to know what to do (for exampe adding extra code) to show the video samples at cart.php . The images i posted with the php code, Is (from what I believe) the code what's needed to show the mp3-files at cart.php . I thought it's something with copying the code and changing the id's and variables, but this didn't work out for me.