PHPackages                             mortimer333/orator - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Database &amp; ORM](/categories/database)
4. /
5. mortimer333/orator

ActiveLibrary[Database &amp; ORM](/categories/database)

mortimer333/orator
==================

04PHP

Since Oct 4Pushed 3y ago1 watchersCompare

[ Source](https://github.com/Mortimer333/Orator)[ Packagist](https://packagist.org/packages/mortimer333/orator)[ RSS](/packages/mortimer333-orator/feed)WikiDiscussions master Synced 2w ago

READMEChangelogDependenciesVersions (1)Used By (0)

Orator (WIP)
============

[](#orator-wip)

PHP logger

Overview
========

[](#overview)

Helpful library for pretty logging (no more vardump mess). No css just indents and `JSON_PRETTY_PRINT` (best use case is inside files but `` should also suffice).

How to use
==========

[](#how-to-use)

```
use Orator\Log;

Log::log('Log A'); // Log A

Log::increaseIndent();
Log::log('Log B'); // →→Log A
Log::decreaseIndent();

Log::log(['asd' => 'asd']);
/*
    Output:
    {
        "asd": "asd"
    }
 */

$log = "First line
Second Line";
Log::log($log); // First line\nSecond Line

// Set $addClass and $addFunction to true
class LogClass
{
    public static function test()
    {
        Log::log('Test');
    }
}
LogClass::test(); // Tetraquark\LogClass | test * Test
```

Options
=======

[](#options)

Currently there is almost no option to change how logger behave mid run so any changes have to be made directly inside the `Log` file.

Verbose
-------

[](#verbose)

You can define how important log output is by passing it as second parameter to `Log` method:

```
Log::log("log", 2);
```

If `$maxVerbose` is bigger or equal `$verbose` inside the log it will be outputed.

Trace Level
-----------

[](#trace-level)

When `$addClass` and `$addFunction` are enabled you can decide how much back on debug trace you want to go:

```
class LogClass
{
    public static function test(int $trace = 0)
    {
        Log::log('Test', null, $trace);
    }

    public static function testNested()
    {
        self::test(1);
    }
}

LogClass::test();       // Tetraquark\LogClass | test * Test
LogClass::testNested(); // Tetraquark\LogClass | testNested * Test
```

Run time
--------

[](#run-time)

By calling `timerStart` and `timerEnd` you will get how much time flown between those calls in 1000th of the second:

```
Log::timerStart();
for ($i=0; $i < 10**6; $i++) {
    // code...
}
Log::timerEnd(); // Duration: 0.024s
```

Stop replacing of the new lines
-------------------------------

[](#stop-replacing-of-the-new-lines)

If you want to display new lines inside of the log set `$replaceNewLine` to false in `Log` method:

```
Log::log("Line 1\nLine 2", replaceNewLine: false);
/*
    Output:
    Line 1
    Line 2
 */
```

###  Health Score

14

—

LowBetter than 1% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity3

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity25

Early-stage or recently created project

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://www.gravatar.com/avatar/c3dbf637bda39a5c8bd9102bf5a02d3333fc22d58c11348f0d4c66194e7d7f32?d=identicon)[Mortimer333](/maintainers/Mortimer333)

---

Top Contributors

[![Mortimer333](https://avatars.githubusercontent.com/u/34005580?v=4)](https://github.com/Mortimer333 "Mortimer333 (1 commits)")

### Embed Badge

![Health badge](/badges/mortimer333-orator/health.svg)

```
[![Health](https://phpackages.com/badges/mortimer333-orator/health.svg)](https://phpackages.com/packages/mortimer333-orator)
```

###  Alternatives

[jdorn/sql-formatter

a PHP SQL highlighting library

3.9k116.5M113](/packages/jdorn-sql-formatter)[propel/propel1

Propel is an open-source Object-Relational Mapping (ORM) for PHP5.

8351.6M87](/packages/propel-propel1)[yemenopensource/filament-excel

This package useful for importing excel files into models.

194.2k](/packages/yemenopensource-filament-excel)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
