I'm currently working on retrieving data from coinmarketcap API and I would like to limit the strings to 5. I retrieve the data and then multiply the value *1.07
and the result to MXN
, but the string is long, like 25.65675734343
, I want to limit that string, this is my echo:
echo $xrpprice*$rate*$fxrates['rates']['MXN'];