i have a column with numbers that have 3 decimals:
<?php
require_once 'conn.php';
$sql = "SELECT * FROM `mybdd`";
$query = $conn->prepare($sql);
$query->execute();
while($fetch = $query->fetch())
{
<?php echo $fetch['score']?>
}
?>
It will show ‘score’ values from the table mybd
like:
SCORES
------
20,025
30,016
25,045
etc
What can i do to get ‘score’ values with only 2 decimals like:
SCORES
------
20,02
30,01
25,04
Thanks
get the correct php code