|
Page 5 of 6
MISC Functions
General Functions
- if elseif else is 0.78 % faster than switch
- @Error supression is 235% slower than without
- $_SERVER['REQUEST_TIME'] is 59% faster than time()
- min(array) is 16% faster than min(int, int)
- require_once() is 24% faster than include()
- require_once() is just as fast as include_once()
- include(relative path) is 37% faster than include(full path)
Regular Expressions
- str_replace() is 40% faster than preg_replace()
- ereg('regex') is 17% faster than preg_match('/regex/')
- preg_match('/regex/i') is 68% faster than eregi('regex')
|