I have a Codeigniter application, in which I am logging the error, debug and info messages. In config.php, I have set the threshold value as 4. I could see the log file in application/log folder. Now I tried to add a custom log from a method from a controller. I used
log_message("error", "this is my custom error");
But this is not logging in the log file. What I tried so far
- Changed the log file location
- Changed the log file permission
- Changed the level with 'debug', 'info'.
- Applied the changes in server files to see if it works in another server.
Nothing writing the log. In the existing log file, I can see the log messages from core files. I cannot write anything from the application folder.