PHP

Support group for those afflicted with PHP. Don't ask to ask, ...
Aug 14, 2014 16:41
Thanks Dave!
Aug 14, 2014 16:39
do you mean as a solution? or to see what the actual values are?
Aug 14, 2014 16:37
Situation is this. I'm trying to fix some code that is provided by an external developer. Locally it works fine, but on the server it thinks that "18.9 < 18.9". I don't/can't change too much in the code. I just want to make the comparison work reliably. No single-line solution I assume though... :S
Aug 14, 2014 16:35
DaveRandom: Money
Aug 14, 2014 16:34
What should I do if I just want to compare two values, let's say $some->method() and $someVar, and I don't know what type to expect? It's always a unit of money though. I just thought adding floatval() would help... :)
Aug 14, 2014 16:33
Would that be a recommended solution for my use case?
Aug 14, 2014 16:32
Oh. Sounds complicated. :) It does only happen on my server though and not locally so it must be something quite tricky.
Aug 14, 2014 16:30
how can two identical floats be different? :/
Aug 14, 2014 16:29
Losing my mind over this, probably making a very stupid mistake, but can anybody make sense of this? pastebin.com/a1wTfiAs