Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

WordPress

Joe Li
Joe Li
8,104 Points

Best way to create a woocommerce child theme within your own theme.

Hey Guys,

I'm pretty new to wordpress and woocommerce, so sorry if this is a stupid question.

I've created a theme called HSX, and I've installed WooCommerce as a plugin. Should I create a child theme of WooCommerce so that if there are any updates it doesn't effect the styling changes i will make? If so how do i do it and what repository is it suppose to go in?

Thanks,

Joe

2 Answers

Zac Gordon
STAFF
Zac Gordon
Treehouse Guest Teacher

No, WooCommerce is just a plugin so updating the plugin will not effect your theme unless there is a major update to WooCommerce and you're using outdated code.

Joe Li
Joe Li
8,104 Points

Hey Zac, I've styled and edited the WooCommerce files before using bootstrap. Then I updated the plugin and it removed all my restructuring and styling? I thought that a child theme would help to eliminate this issue, meaning that any updates wouldn't directly effect the plugin?

Zac Gordon
STAFF
Zac Gordon
Treehouse Guest Teacher

You can't edit the template files in the WooCommerce plugin. You have to copy them over into your own theme. Check out our course on WooCommerce, specifically the bonus video at the end that shows how to do this :)

http://teamtreehouse.com/library/ecommerce-with-wordpress-and-woocommerce/running-an-ecommerce-site-long-term/bonus-video-how-to-begin-customizing-woocommerce-template-files

Joe Li
Joe Li
8,104 Points

Will check it out, thanks again for your help Zac. Merry Xmas!