Download the PHP package seunmatt/codeigniter-log-viewer without Composer

On this page you can find all versions of the php package seunmatt/codeigniter-log-viewer. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package codeigniter-log-viewer

CodeIgniter Log Viewer

Latest Stable Version Total Downloads License

This is a simple Log Viewer for viewing CodeIgniter logs in the browser or via API calls (that returns a JSON response)

This project is inspired by the laravel-log-viewer project.

A typical log view looks like this:

Usage

For CodeIgniter 3, see this reference guide

Requirements

Composer Installation

Controller Integration for Browser Display

All that is required is to execute the showLogs() method in a Controller that is mapped to a route:

A typical Controller (LogViewerController.php) will have the following content:

Then the route app/Config/Routes.php can be configured like:

And that's all! If you visit /logs on your browser you should see all the logs that are in writable/logs folder and their content

Configuration

The package allows you to configure some of its parameters by creating a CILogViewer class in CodeIgniter's Config folder and then adding the following variables:

Example configuration file app/Config/CILogViewer.php:

Viewing Log Files via API Calls

If you're developing an API Service, powered by CodeIgniter, this library can still be used to view your log files.

Controller Setup

The setup is the same as that mentioned above:

Response:

file_b64 is the base64 encoded name of the file that will be used in further operations and API calls

Query:

Query:

/logs?api=view&f=bG9nLTIwMTgtMDEtMTkucGhw&sline=false OR logs?api=view&f=bG9nLTIwMTgtMDEtMTkucGhw

Response:

Query:

/logs?api=delete&f=bG9nLTIwMTgtMDEtMTkucGhw will delete a single log file. The f parameter is the base64 encoded name of the file and can be obtained from the view api above.

Query:

/logs?api=delete&f=all will delete all log files in the configured folder path. Take note of the value for f which is the literal 'all'.

IF A FILE IS TOO LARGE (> 50MB), YOU CAN DOWNLOAD IT WITH THIS API QUERY /logs?dl=bG9nLTIwMTgtMDEtMTcucGhw

SECURITY NOTE

It is Highly Recommended that you protect/secure the route for your logs. It should not be an open resource!

Change Log

Change Log is available here

Author

Contributors

LICENSE

MIT


All versions of codeigniter-log-viewer with dependencies

PHP Build Version
Package Version
Requires php Version >=7.4
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package seunmatt/codeigniter-log-viewer contains the following files

Loading the files please wait ....