How to store $_POST value permanently in PHP?
<p>Note sure how to explain this clearly but here is the problem:</p>

<p>I have a multi-page form process which takes the customer from a shopping cart page to a shipping page. On the cart page there is a hidden field called totalPrice which has as it's value an integer. I am calling this total on the shipping page like so:</p>

<pre><code>$total = $_POST['totalCost'];
echo $total;
</code></pre>

<p>On this shipping page there is another form which asks the customer to choose a shipping method. When this form is submitted the totalCost is to be updated to reflect the added shipping cost.</p>

<p>I am trying to do that like this:</p>

<pre><code>$total = $total + $shippingCost;
</code></pre>

<p>But this only shows the shipping cost when I echo $total again not the shipping added to the initial total. I guess that's because the form has been submitted and the initial $total hidden value carried on from the previous form is lost.</p>

<p>So Is there any way to make the initial totalPrice value permanent so that I can add the shipping cost to it as well?</p>
