X7ROOT File Manager
Current Path:
/home/prisjneg/public_html/vendor/monolog/monolog/src/Monolog/Handler
home
/
prisjneg
/
public_html
/
vendor
/
monolog
/
monolog
/
src
/
Monolog
/
Handler
/
๐
..
๐
AbstractHandler.php
(2.61 KB)
๐
AbstractProcessingHandler.php
(1.46 KB)
๐
AbstractSyslogHandler.php
(3.15 KB)
๐
AmqpHandler.php
(4.95 KB)
๐
BrowserConsoleHandler.php
(9.02 KB)
๐
BufferHandler.php
(4.55 KB)
๐
ChromePHPHandler.php
(4.79 KB)
๐
CouchDBHandler.php
(2.55 KB)
๐
CubeHandler.php
(5.32 KB)
๐
Curl
๐
DeduplicationHandler.php
(6.25 KB)
๐
DoctrineCouchDBHandler.php
(1.12 KB)
๐
DynamoDbHandler.php
(1.89 KB)
๐
ElasticaHandler.php
(3.66 KB)
๐
ElasticsearchHandler.php
(7.1 KB)
๐
ErrorLogHandler.php
(2.61 KB)
๐
FallbackGroupHandler.php
(1.68 KB)
๐
FilterHandler.php
(6.92 KB)
๐
FingersCrossed
๐
FingersCrossedHandler.php
(7.99 KB)
๐
FirePHPHandler.php
(5.03 KB)
๐
FleepHookHandler.php
(3.44 KB)
๐
FlowdockHandler.php
(3.4 KB)
๐
FormattableHandlerInterface.php
(757 B)
๐
FormattableHandlerTrait.php
(1.24 KB)
๐
GelfHandler.php
(1.42 KB)
๐
GroupHandler.php
(3.19 KB)
๐
Handler.php
(1.21 KB)
๐
HandlerInterface.php
(2.71 KB)
๐
HandlerWrapper.php
(3.28 KB)
๐
IFTTTHandler.php
(2.22 KB)
๐
InsightOpsHandler.php
(2.04 KB)
๐
LogEntriesHandler.php
(1.86 KB)
๐
LogglyHandler.php
(4.02 KB)
๐
LogmaticHandler.php
(2.57 KB)
๐
MailHandler.php
(2.19 KB)
๐
MandrillHandler.php
(2.48 KB)
๐
MissingExtensionException.php
(473 B)
๐
MongoDBHandler.php
(2.31 KB)
๐
NativeMailerHandler.php
(5.08 KB)
๐
NewRelicHandler.php
(5.7 KB)
๐
NoopHandler.php
(908 B)
๐
NullHandler.php
(1.3 KB)
๐
OverflowHandler.php
(4.21 KB)
๐
PHPConsoleHandler.php
(12.01 KB)
๐
ProcessHandler.php
(5.36 KB)
๐
ProcessableHandlerInterface.php
(1.16 KB)
๐
ProcessableHandlerTrait.php
(1.58 KB)
๐
PsrHandler.php
(2.41 KB)
๐
PushoverHandler.php
(7.92 KB)
๐
RedisHandler.php
(2.67 KB)
๐
RedisPubSubHandler.php
(1.64 KB)
๐
RollbarHandler.php
(3.48 KB)
๐
RotatingFileHandler.php
(6.97 KB)
๐
SamplingHandler.php
(3.83 KB)
๐
SendGridHandler.php
(3.02 KB)
๐
Slack
๐
SlackHandler.php
(6.99 KB)
๐
SlackWebhookHandler.php
(3.79 KB)
๐
SocketHandler.php
(11.84 KB)
๐
SqsHandler.php
(1.71 KB)
๐
StreamHandler.php
(7.96 KB)
๐
SymfonyMailerHandler.php
(3.45 KB)
๐
SyslogHandler.php
(1.65 KB)
๐
SyslogUdp
๐
SyslogUdpHandler.php
(4.6 KB)
๐
TelegramBotHandler.php
(9.22 KB)
๐
TestHandler.php
(6.6 KB)
๐
WebRequestRecognizerTrait.php
(504 B)
๐
WhatFailureGroupHandler.php
(1.87 KB)
๐
ZendMonitorHandler.php
(2.78 KB)
Editing: ErrorLogHandler.php
<?php declare(strict_types=1); /* * This file is part of the Monolog package. * * (c) Jordi Boggiano <j.boggiano@seld.be> * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ namespace Monolog\Handler; use Monolog\Formatter\LineFormatter; use Monolog\Formatter\FormatterInterface; use Monolog\Level; use Monolog\Utils; use Monolog\LogRecord; /** * Stores to PHP error_log() handler. * * @author Elan Ruusamรคe <glen@delfi.ee> */ class ErrorLogHandler extends AbstractProcessingHandler { public const OPERATING_SYSTEM = 0; public const SAPI = 4; /** @var 0|4 */ protected int $messageType; protected bool $expandNewlines; /** * @param 0|4 $messageType Says where the error should go. * @param bool $expandNewlines If set to true, newlines in the message will be expanded to be take multiple log entries * * @throws \InvalidArgumentException If an unsupported message type is set */ public function __construct(int $messageType = self::OPERATING_SYSTEM, int|string|Level $level = Level::Debug, bool $bubble = true, bool $expandNewlines = false) { parent::__construct($level, $bubble); if (false === \in_array($messageType, self::getAvailableTypes(), true)) { $message = sprintf('The given message type "%s" is not supported', print_r($messageType, true)); throw new \InvalidArgumentException($message); } $this->messageType = $messageType; $this->expandNewlines = $expandNewlines; } /** * @return int[] With all available types */ public static function getAvailableTypes(): array { return [ self::OPERATING_SYSTEM, self::SAPI, ]; } /** * @inheritDoc */ protected function getDefaultFormatter(): FormatterInterface { return new LineFormatter('[%datetime%] %channel%.%level_name%: %message% %context% %extra%'); } /** * @inheritDoc */ protected function write(LogRecord $record): void { if (!$this->expandNewlines) { error_log((string) $record->formatted, $this->messageType); return; } $lines = preg_split('{[\r\n]+}', (string) $record->formatted); if ($lines === false) { $pcreErrorCode = preg_last_error(); throw new \RuntimeException('Failed to preg_split formatted string: ' . $pcreErrorCode . ' / '. preg_last_error_msg()); } foreach ($lines as $line) { error_log($line, $this->messageType); } } }
Upload File
Create Folder