A
A
Anton2020-05-14 17:47:21
WordPress
Anton, 2020-05-14 17:47:21

How to add an array of custom attributes to a WooCommerce product using php?

How to add an array of custom attributes to a WooCommerce product using php?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Anton, 2020-05-14
Veida @aveyda7

I figured it out myself. Everything turned out to be simple.

update_post_meta( $product_id, '_product_attributes', $attributes );

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question