This is a simple PHP script that pulls a log file from the Apache logs and formats it for display in a web browser. To set it up on your machine, pass in the Apache log file name to the SimpleLogViewer constructor in index.php. You may need to set permissions on your log file to view it.
Example: sudo chmod 755 /var/log/apache2/error.log
Instead of viewing Apache logs in Terminal on a Mac like this:
We can view them in a browser like this:
- TODO: add heartbeat AJAX request to update the UI
- TODO: display all logs from /var/log/apache2/, then user can click to view one