Welcome Guest, Not a member yet? Register   Sign In
Twice loading config's files
#1

Hello, help please

1. We traced php process which works on Code Igniter and we get data:
access("/var/www/name.com/apps_files/config/config.php", F_OK) = 0
access("/var/www/name.com/apps_files/config/production/config.php", F_OK) = -1 ENOENT (No such file or directory)

2. We fix it and created symlink /production/config.php to /config/config.php and look: is it will enought if it will find file from first time and we get next data
access("/var/www/name.com/apps_files/config/config.php", F_OK) = 0
access("/var/www/name.com/apps_files/config/production/config.php", F_OK) = 0

 Problem that core CI load twice same config file, how we can fix it? 
Reply
#2

It was working fine before you broke it. Of course it load twice now that you created a symlink to the same file! Why did you do that? The second file is there to set configuration for a specific environment to override the global configuration.
CodeIgniter 4 tutorials (EN/FR) - https://includebeer.com
/*** NO support in private message - Use the forum! ***/
Reply




Theme © iAndrew 2016 - Forum software by © MyBB