$conf, $runtime; function_exists('chdir') AND chdir(APP_PATH); $r = 'mysql' == $conf['cache']['type'] ? website_set('runtime', $runtime) : cache_set('runtime', $runtime); } function runtime_truncate() { global $conf; 'mysql' == $conf['cache']['type'] ? website_set('runtime', '') : cache_delete('runtime'); } register_shutdown_function('runtime_save'); ?>customization - How to add product variations for large number of products in WooCommerce?|Programmer puzzle solving
最新消息:Welcome to the puzzle paradise for programmers! Here, a well-designed puzzle awaits you. From code logic puzzles to algorithmic challenges, each level is closely centered on the programmer's expertise and skills. Whether you're a novice programmer or an experienced tech guru, you'll find your own challenges on this site. In the process of solving puzzles, you can not only exercise your thinking skills, but also deepen your understanding and application of programming knowledge. Come to start this puzzle journey full of wisdom and challenges, with many programmers to compete with each other and show your programming wisdom! Translated with DeepL.com (free version)

customization - How to add product variations for large number of products in WooCommerce?

matteradmin9PV0评论

I have a Wordpress site with WooCommerce selling photo prints. Currently there are around 150 photos. I managed to import the photos as products fine, but each print has 3 sizes.

I've added a Size attribute with 3 "terms" for the variations. But adding these to the products one by one will take forever. There must be a quicker way!

I've tried exporting all the products and adding the variations in the CSV (copying the variations I added for the first few products and changing all relevant IDs/SKUs), but reimporting doesn't do anything - no variations are added for other products.

I've even tried diff-ing the database before and after adding variations manually, and thought I'd figured out exactly what I needed to add... but adding posts and postmetas to the database still doesn't add the variations! Surely there is an easier way?!

Post a comment

comment list (0)

  1. No comments so far