I'd like to show a "Free Shipping" Incentive in the cart so that customers now that they have to add a certain amount to receive free shipping. I work my free shipping with table rates and not the free shipping module.
I found this script but unfortunately its not really working. Any idea how I can get something like this to work?
<?php if ($this->getQuote()->getSubtotal() < 100): ?> <?php $subtotalamt = $this->getQuote()->getSubtotal(); ?> <?php $freeshipamt = 100; ?> <?php $sumtotal = $freeshipamt - $subtotalamt; ?> <?php Mage::helper('checkout')->formatPrice($sumtotal); ?> <p>You are just <span>$<?php print ($sumtotal); ?></span> away from earning free shipping!</p> <?php endif ?>
It should read the Cart Total incl. tax and then just show the difference to the price I define.
Edit: I inserted the script in /app/design/frontend/theme/default/checkout/cart_new.phtml (my cart template) and tried to get it working there. It should then show the sentence: "You are just $XXX,- away from earing free shipping!"
But unfortunately it is not showing anything at all.