Want to add a little function

I don't know what this support all about I need a small snippet may be to add in woocommerce variation