The goal is to show the total price of a purchase of a particular product based on the quantity ordered. Example if you wish to buy 3 mugs for $50, then a “Total: $150” ¬†will be shown. If you wish to changed it to something like quantity of 5, then it will display¬†“Total: $250”, and so on..
Now. which hook to use? I particularly choose “woocommerce_single_product_summary”.
You can see it on in content-single-product.php in the templates folder of woocommerce. It’s something like below:

 * woocommerce_single_product_summary hook
 * @hooked woocommerce_template_single_title - 5
 * @hooked woocommerce_template_single_rating - 10
 * @hooked woocommerce_template_single_price - 10
 * @hooked woocommerce_template_single_excerpt - 20
 * @hooked woocommerce_template_single_add_to_cart - 30
 * @hooked woocommerce_template_single_meta - 40
 * @hooked woocommerce_template_single_sharing - 50
do_action( 'woocommerce_single_product_summary' );

The numbers there will be it’s position. I don’t have to explain everything in there. You should get a hint by now of what it’s doing.
So our code would be like this:

// we are going to hook this on priority 31, so that it would display below add to cart button.
add_action( 'woocommerce_single_product_summary', 'woocommerce_total_product_price', 31 );
function woocommerce_total_product_price() {
    global $woocommerce, $product;
    // let's setup our divs
    echo sprintf('',__('Product Total:','woocommerce'),''.$product->get_price().'');
    echo sprintf('',__('Cart Total:','woocommerce'),''.$product->get_price().'');
                var price = get_price(); ?>,
                    current_cart_total = cart->cart_contents_total; ?>,
                    currency = '';
                    if (!(this.value < 1)) {
                        var product_total = parseFloat(price * this.value),
                        cart_total = parseFloat(product_total + current_cart_total);
                        $('#product_total_price .price').html( currency + product_total.toFixed(2));
                        $('#cart_total_price .price').html( currency + cart_total.toFixed(2));
                    $('#product_total_price,#cart_total_price').toggle(!(this.value <= 1));

Paste this in your functions.php and you will have something like this image below:
Product total price
Please take note that this will only work on Simple Product page. Also price calculation may not be exact with other plugins changing the price. If you need an accurate calculation that will work with other product types, try my listed plugin below.
If you have questions, let me know in comments below.


By popular requests, here’s a plugin that can do more than this tutorial.
WooCommerce Product Price x Quantity Preview. This is compatible with WooCommerce Dynamic Pricing & Discounts.