-
-
Notifications
You must be signed in to change notification settings - Fork 506
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
WooCommere variable or grouped product display sample? #1605
Comments
I have just finished writing an integration guide for WooCommerce, but it is awaiting approval. (it is quite a long guide.) In the integration with WooCommerce, quite a bit is using and calling the built in functions in WC, and using filters to adjust accordingly. As for variations on the single product, I assume by showing you are referring to showing a variation based upon an attribute? Like if an Item comes in red, and the user chooses "Red" it will show the product's red image? This type of behavior that can be seen here: https://demo-store.proweb.agency/timber-boot-store/vape-mods/smok/ and you choose the color and the image changes. If this is what you mean, I can post the code here.
All, is kind of a lot, but as stated, when I did the integration I called the functions, built into WC, makes it easier when it is time to upgrade. Here is an example of my single-product.twig:
Hope that helps. If you need any more code, let me know, I will share until the guide come out. --Jake |
@stromi is this issue resolved for you? Feel free to ask further here otherwise please close this ticket. |
Hello @jake46a , any news about your guide? I am struggeling to work with variations product : like display only the price of the current variations or display the product gallery. |
@aureliendebord here's his guide: Could you take a spin and see if this helps to answer your Qs? It'd be great to get a second set of eyes on what he's written (I'm not a WC user, so I'm not much help) before we merge it in |
Closing this as stale. If you want to expand the Woocommerce documentation, please open a PR. |
Does anyone has a sample code/gist for recreating all WooCommerce functions and behavior for Timber?
Expected behavior
I would like to show variations of a product on
single-product.twig
, but I can't make it work.Actual behavior
Dumping the current product (post) does show some attributes at
_custom
, but this just won't be enough I think :)What version of WordPress, PHP and Timber are you using?
WP: 4.8, PHP: 7.1.1, Timber: 1.5 (integrated into the theme)
How did you install Timber? (for example, from GitHub, Composer/Packagist, WP.org?)
Composer --> integrated into the theme (everything else works just fine)
The text was updated successfully, but these errors were encountered: