php round decimal
snippet in php

php round 2 decimals

user7331

$value = 4.96754;
round($value, 2);
//returns 4.97

php round decimal

user5369

$value = 1.23456789;
$rounded_value = round($value, 2); 
// 2 is the precision here we will get 1.23