daily pastebin goal
23%
SHARE
TWEET

Untitled

a guest Mar 20th, 2019 54 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. $customer = $_POST['customer'];
  2. $statement = $connection->prepare($sql);
  3. $statement->bindParam(':customer', $customer, PDO::PARAM_STR);
  4. $statement->bindValue(':total_value', $total_value, PDO::PARAM_INT);
  5. $statement->bindValue(':total_balance', $total_balance, PDO::PARAM_INT);
  6. $statement->execute();
  7. $result = $statement->fetchAll();
  8. $total_value_result = $statement->fetch_assoc;
  9.  
  10. $sum = array_sum(array_column($total_value_result, 'total_value_result'));
  11.     echo $sum['total_value'];
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top