Re: Turning a string into a condition

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Am 16.02.12 22:37, schrieb Marc Guay:
> 2) The range of possibilities are broader than I indicated. They would
> like to be able to enter conditions of all sorts. i.e. ($x / $y) > 0.5
> (($a+$b+$c) / $d) < .75 etc. If you have any suggestions on how to
> increase the security while maintaning the flexibility, I'd be happy
> to hear it. Marc 

Is math all you want to use? Parsing will be an easy doing and I am
pretty sure there are a lot of examples around the web.
E.g.:
http://www.phpclasses.org/package/2695-PHP-Safely-evaluate-mathematical-expressions.html



-- 
Marco Behnke
Dipl. Informatiker (FH), SAE Audio Engineer Diploma
Zend Certified Engineer PHP 5.3

Tel.: 0174 / 9722336
e-Mail: marco@xxxxxxxxxx

Softwaretechnik Behnke
Heinrich-Heine-Str. 7D
21218 Seevetal

http://www.behnke.biz


Attachment: signature.asc
Description: OpenPGP digital signature


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux