CodeIgniter Forums
Creating a application config file - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20)
+--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23)
+--- Thread: Creating a application config file (/showthread.php?tid=21327)



Creating a application config file - El Forum - 08-06-2009

[eluser]eokorie[/eluser]
Hi all,

I am looking to create a config file for an application I am currently working on. What I am trying to achieve is to allow someone to change values of the config from a backend admin page instead of having to dive into the file itself to change things by hand. For example, if a site is offline for maintenance, the user can simply click on a checkbox and the value of this is changed in the config file.

is there an easy way to do this?

any help will be appreciated.

Thanks


Creating a application config file - El Forum - 08-06-2009

[eluser]bretticus[/eluser]
Instead of writing to a file (and a PHP one at that!) I'd just toggle this from a database call instead.