Update or show cart items and their price(total) into header.phtml than

Copy and paste below code

<?php
                                                             $count = $this->helper('checkout/cart')->getSummaryCount();  //get total items in cart
                                                              $total = $this->helper('checkout/cart')->getQuote()->getGrandTotal(); //get total price
                                                  if($count==0)
                                                  {
                                                            echo $this->__('<span>%s</span> Item(s):',$count);
                                                  }
                                                  if($count==1)
                                                  {
                                                            echo $this->__('<span>%s</span> Item(s):',$count);
                                                  }
                                                  if($count>1)
                                                 {
                                                            echo $this->__('<span>%s</span> Item(s):',$count);
                                                }
                                                echo $this->__(' <span>%s</span>', $this->helper('core')->formatPrice($total, false));
                                                            ?>

Comments