I am working on a small project and must somehow implement internationalization. I’m thinking about how to use constants to define a large number of characters for text in a single file, which can later be included. However, I’m not sure if using variables is faster, or I can avoid using associative arrays without an excessive amount of performance hit.
What is better for determining constant values in PHP, in terms of performance, are constants defined using define("FOO", "...")either simple type variables $foo = "..."or associative type arrays $symbols["FOO"]?
source
share