BCMath Arbitrary Precision Mathematics Functions
Moderator: General Moderators
BCMath Arbitrary Precision Mathematics Functions
I need to use this but my host's PHP is not compiled with it... Is there a way to load this module so that I can use the functions?
http://www.php.net/manual/en/ref.bc.php
looks to me like someone needs to have a chat with a network administrator
looks to me like someone needs to have a chat with a network administrator
-
Agent Dwarf
- Forum Newbie
- Posts: 9
- Joined: Sat Sep 21, 2002 2:03 pm
I'VE GOT A NEW VERSION, so it works when I test it on my computer. But when I put it onto my host it doesn't
I was just wondering whether PHP could include a module for BCMath Arbitrary Precision Mathematics Functions (if it does exist). Looks like I can't, is there any simliar function to bcsub() then? That's the function I need to use...
- hob_goblin
- Forum Regular
- Posts: 978
- Joined: Sun Apr 28, 2002 9:53 pm
- Contact:
Agent Dwarf wrote:Well, if you don't have it automatically, that means you have an old version of PHP. You should probably get the latest version, at php.net.
It's exactly the opposite.
About including it: no, php isn't like python, or c++, sorry.
About another function: What exactly does it do? I can probably write one.
I'm trying to subtract a microtime() with microtime() (I'm just trying to find out how long it took for the page to load.) So here's the code
If I do it just simply with "-" it would't work...
Code: Select all
<?php
$start_time = explode(" ",microtime());
$start = $start_timeї1].substr($start_timeї0],1,10);
//Lots of code
$end_time = explode(" ",microtime());
$end = $end_timeї1].substr($end_timeї0],1,10);
$time = @bcsub($end,$start,7);
?>