Re: [PHP] Round
- From: richardh@xxxxxxxxxxx (Richard Heyes)
- Date: Wed, 29 Aug 2007 16:20:44 +0100
Koen van den Boogaart wrote:
Is it expected behaviour that
<?php var_dump( round(-0.26) ); ?>
outputs
float(-0)
Yes. You (probably) want:
<?php
var_dump(round(-0.26, 1));
?>
http://uk.php.net/manual/en/function.round.php
--
Richard Heyes
+44 (0)844 801 1072
http://www.websupportsolutions.co.uk
Knowledge Base and HelpDesk software
that can cut the cost of online support
.
- Follow-Ups:
- Re: [PHP] Round
- From: "Koen van den Boogaart"
- Re: [PHP] Round
- References:
- Round
- From: "Koen van den Boogaart"
- Round
- Prev by Date: Round
- Next by Date: RE: [PHP] Regular expression - URL validator
- Previous by thread: Round
- Next by thread: Re: [PHP] Round
- Index(es):
Relevant Pages
|