PHP, has a solution to log all of your errors to a specific log file. It's simple, as you just have to add a line of code to your php.ini file. For this example we'll create a log file in the root directory: /home/username/phperror.log (dont forget to replace the username in the file path with your actual cPanel username):

error_log = /home/username/phperror.log

For detail detailed information on this, see the article on Display and log errors for PHP.

If you would like more information on working with your php.ini file, please review the following article:

Updating your local PHP settings

You will also need to write a basic PHP script to generate and update the log file. For more information on sending PHP errors to a log file please review the following link:

http://www.php.net/manual/en/function.error-log.php

If you are looking for the general error log for your cPanel account. you can find it within cPanel itself. On the cPanel home screen, click on the "Error Log" icon.

cpanel-error-log

Like this Article?

Login to comment.

Your Opinion Matters

... but we need to know what you're thinking!

I'm Tim Sisson, your friendly Community Support technician, and I wrote the article you're looking at now. I like to think it's perfect, but I'm sure you have some suggestions. Please, let me know what they are!

Feedback
Your Email Address
Because we'd like to talk with you!

Latest Questions

If you need some help, submit your question to our Community!
We guarantee a response within 60 minutes (8am - 9pm EST, Monday - Friday)
Ask a Question!
Recent Questions
  1. Internal error 500
  2. register and order details
  3. 10+ hours offline and no solution. Why?

Need more Help?

Search

Ask the Community!

Get help with your questions from our community of like-minded hosting users and InMotion Hosting Staff.

Current Customers

Chat: Click to Chat Now E-mail: support@InMotionHosting.com
Call: 888-321-HOST (4678) Ticket: Submit a Support Ticket

Not a Customer?

Get web hosting from a company that is here to help. Sign up today!