Take the 2-minute tour ×  Almost every public CMS out there uses
a .php configuration file for the database settings and so on.
For example WordPress automatically creates a .php config file
when you install it.  Why don't they just use a .ini file? PHP
already has parse_ini_file() and I'm sure other languages have
similar functions.  share|improve this question add comment  4
Answers  up vote 7 down vote accepted  With PHP in particular;
the difference between an .ini file and a .conf.php file is
negligible.  Using PHP directly for configuration has the
distinct advantage of only needing to relate to one well-
defined, portable syntax for configuration, and the fact that
the configuration file is properly code is occasionally useful.
Compared to that; an ini file has little to nothing to offer;
and include, require and require_once are all well-known and
(mostly) well understood.  share|improve this answer relate to
one well-defined, portable syntax for configuration I don't get
that. ini files have a well-d