Load settings from database at bootstrap |
[eluser]Saquib[/eluser]
I want to load some settings from database in my application, I am planing to do that using a model which will be auto-loaded from config. In model construct i will perform actions like a db query and fetch settings and store it in session for later use. Quote:Application is allowed access from current ip address My Question is Quote:What is the right way to load settings which should be available at very early stage in app (on bootstrap) ? Please help !
[eluser]Procode[/eluser]
If you dont want to store the data in a database you can always create a custom config file. It tells you exactly how in the user guide.
[eluser]Saquib[/eluser]
[quote author="Procode" date="1347848928"]If you dont want to store the data in a database you can always create a custom config file. It tells you exactly how in the user guide.[/quote] My Settings are saved in Database, i need to use some other way to solve it. I am going to try below solution :-) http://ellislab.com/forums/viewthread/223925/
[eluser]CroNiX[/eluser]
I just extend the Controller with MY_Controller and have MY_Controller get that data from the database and stick it in an array, which anything else can then use. |
Welcome Guest, Not a member yet? Register Sign In |