The built-in PHP error_log() function sends an error message to the web server's error log, a TCP port or to a file.
Syntax
bool error_log ( string $message [, int $message_type [, string $destination [, string $extra_headers]]] )
Parameter Details
Sr.No | Parameter & Description |
---|---|
1 | message The error message that should be logged. |
2 | message_type It says where the error should go. The possible message types are as follows −
|
3 | destination The destination. Its meaning depends on the message_type parameter as described above. |
4 | extra_headers The extra headers. It's used when the message_type parameter is set to 1. This message type uses the same internal function as mail() does. |
Return Value
Do feel free to ask your questions where necessary and we will attend to them as soon as possible. If this tutorial was helpful to you, you can use the share button to share this tutorial.
Follow us on our various social media platforms to stay updated with our latest tutorials. You can also subscribe to our newsletter in order to get our tutorials delivered directly to your emails.
Thanks for reading and bye for now.