Shopping cart doesn't automatically update

So I grabbed the code from the gridmarket theme for the cart updated at the top of the website. This code shows how many items are in the persons cart and gives a link to the shopping cart.

On my website it only updates when a new page is visited or the current page is refreshed. Here is the link to it.

Is there a way to get it to update right away?

~Garret (Web Designer @ Polishpedia)