Welcome Guest, Not a member yet? Register   Sign In
Write to config file
#2

You can create CodeIgniter config.tpl files with dummy values and use
str_replace to replace the dummy values with the inputted values.

1) open and read the ./application/config.tpl config file
2) use str_replace to add the correct values
3) save and write the config.php file to the ./application/config folder

This can be used to write any type of CodeIgniter configuration file.

I'll see if I can give you an example later today.
What did you Try? What did you Get? What did you Expect?

Joined CodeIgniter Community 2009.  ( Skype: insitfx )
Reply


Messages In This Thread
Write to config file - by Aleksa95x - 01-04-2018, 05:31 AM
RE: Write to config file - by InsiteFX - 01-05-2018, 03:36 AM
RE: Write to config file - by Aleksa95x - 01-05-2018, 06:45 AM



Theme © iAndrew 2016 - Forum software by © MyBB