How to solve usage of anonymous function below 5.3 php version?
<pre><code>$total_amount=array_sum(array_map(function($item) { 
                            return $item['total_price']; 
                        }, $cartsItems));
</code></pre>

<p>This is my code which returns a total price in cart. I have installed a higher version on my local but the server is 5.2. How can I solve this problem?</p>