I have a little Templating class, that keeps all settings inside the php class.
These settings are: css styles, js scripts, meta tags and titles for every page. (For example on index.php I need some js-scripts, but for contacts.php – other js-files).
It’s not very comfortable to edit this configuration data, because it is in private properties of a class, and while editing programmer can make mistakes in php code).
Is it a good idea to keep this configuration data in external files? Xml/json/ini ?
Will this get site rendering much slower?
using.ini files is great feature in PHP:
According to your comment – loading it’s not that fast. But you can always cache .ini files in memory:
Now it’s perfect solution. 🙂