woocommerce基于重量的不同价格

It is posible in woocommerce to create different prices based in weight to display in a select dropdown?

For example:

food for dogs: 5k = $20 10k = $40 20k = $60

Step 1: Go to product edit page, for which you like to set prices based on weight.

Step 2: Select Product Type as a variable product, see the image below. Create product attribute, save the attribute. I named the attribute weight .

See the image below:

Capture.png

Step 3: Now we need to add product variation, see the image below:

2Capture.png

Step 4: For each of these variation, u can set any prices you want, see the image below

Edit Product ‹ Classique Floors & tile — WordPre.png

Step 5: update the product, that's it.

It is possible in WooCommerce to create different prices based on weight -

In Variable products in WooCommerce that lets you offer a set of variations on a product, with control over prices, stock, image and more for each variation.

Step 1- Set the product type

  • Go to: WooCommerce > Products.

  • Select the Add Product button or Edit an existing product. The Product Data displays.

  • Select Variable product from the Product Data dropdown.

    enter image description here

Step 2- Add attribute.

  • Go to : Products > Attributes

  • Then give name attribute.

  • Save.

enter image description here

  • Then select on weight attribute.

  • Add sub-attribute in weight attribute (5k,10k,15k).

enter image description here

Step 3- Add attributes to use for variations

  • Go to : Products

  • Then select product you set as variable product in step 1

  • Select Attributes then select Custom product attribute(that is weight), and Add.

  • In weight select sub-attribute.

  • Then Select check box used for variation.

  • Save attribute.

enter image description here

Step 4. Add variations

  • Goto:Variations Select Add variation from the drop-down menu, and click Go

  • Select attributes for your variation. To change additional data, click the triangle icon to expand the variation.

  • Edit Price for each attribute.

  • Save Changes.

enter image description here

Read more: https://docs.woocommerce.com/document/variable-product/

Watch this Video- https://www.youtube.com/watch?v=iUcAf89LfCc

https://www.youtube.com/watch?v=aen8ieJuB88