This is an implmentation of PHP's bcmath library. HOWEVER - I stumbled on a test case where it flat out didn't work and so had to roll a specific implementation solution to get my project work done.
Does anyone know of a lib out there that actually works? If not I suppose I'll take this sourceforge project which mostly works and debug it. From the looks of the source code the original author just transliterated the original C code, so he's made a mistake somewhere along the line.
The bad test case is in my thumbs down comment.
That said, I was wondering if anyone had tackled the problem. I was looking for a solution - not an excuse and certainly not a 'do it server side' response.