I would like to change the total in the cart and checkout, multiplying it by 10. (because it currently shows me the 10% deposit price – Woocommerce Deposite plugin -, but I would like to display the total price without deposit).
So I thought about multiplying that by 10.
I’ve created a copy of the cart-totals.php in my child theme. And I would like to modify this string of code to display the price multiplied by 10.
<tr class="cart-subtotal">
<th><?php esc_html_e( 'Subtotal', 'woocommerce' ); ?></th>
<td data-title="<?php esc_attr_e( 'Subtotal', 'woocommerce' ); ?>"><?php wc_cart_totals_subtotal_html(); ?></td>
</tr>
So something like: <?php wc_cart_totals_subtotal_html(); ?> * 10
—-> 6100
Or if it’s simpler, I’d like to add up the prices of the products on the left: 1500+4600 —> 6100
How can I do that?
2
Answers
I added this code in my functions.php file, but nothing has changed.