Launch offer
Business website $150 USD Custom plugin $200 USD Ready in 5 days
Get a quote
CodeIgniter

Logging in CodeIgniter

Write application logs with log_message for debugging and auditing.

Logging in CodeIgniter — a practical guide to CodeIgniter logging with clear examples you can reuse in real projects.

CodeIgniter Tutorial Series (59/74). Prefer one article? Read the complete CodeIgniter tutorial.

Short description

Logs go under `writable/logs`. Use levels like error, warning, info, and debug.

Log messages

log_message('error', 'Payment failed for order {0}', [$orderId]);
log_message('info', 'User logged in');

Leave a reply

Your email address will not be published. Required fields are marked *