Документ взят из кэша поисковой машины. Адрес
оригинального документа
: http://oit.cmc.msu.ru/php/function.version-compare.html
Дата изменения: Sun Feb 3 22:52:37 2002 Дата индексирования: Mon Oct 1 21:57:50 2012 Кодировка: |
version_compare() compares two "PHP-standardized" version number strings. This is useful if you would like to write programs working only on some versions of PHP.
version_compare() returns -1 if the first version is lower than the second, 0 if they are equal, and +1 if the second is lower.
If you specify the third optional operator argument, you can test for a particular relationship. The possible operators are: <, lt, <=, le, >, gt, >=, ge, ==, =, eq, !=, <>, ne respectively. Using this argument, the function will return 1 if the relationship is the one specified by the operator, 0 otherwise.