Reputation: 9856
I have seen a lot of code snippets on the web and examples showing different variations of Zend_Config
and application.ini. Additionally, I have seen some debates about ini config files vs xml config files. I personally have application.ini and a config.xml file.
My application.ini just has basic stuff like php settings and and front controller settings, etc
My config.xml file has some site settings and it also has the db adapter info
As the Zend Framework has progressed I've seen more and more people put almost everything (or so it seems) in application.ini. Should I do the same?
Upvotes: 0
Views: 596
Reputation:
As @mario says .ini style is way more readable for mortals beings while at the same time being not too bad to parse programatically. XML is wizzy easy for parsing (well it is in stuff like java) but awful to read and navigate through. Unless you really need to I would recommend sticking to just using .ini style files. You'll find it alot easier for other people to get up to speed on what configs 'doing'. That said you aren't stuck to just using one config file so feel free to break down configuration sections into multiple .ini files if it makes sense.
Upvotes: 6