This commit is contained in:
2020-02-01 16:47:12 +07:00
commit 4c619ad6e6
16739 changed files with 3329179 additions and 0 deletions

View File

@@ -0,0 +1,48 @@
<?php
/* @var $file string|null */
/* @var $line int|null */
/* @var $class string|null */
/* @var $method string|null */
/* @var $index int */
/* @var $lines string[] */
/* @var $begin int */
/* @var $end int */
/* @var $args array */
/* @var $handler \yii\web\ErrorHandler */
?>
<li class="<?= ($index === 1 || !$handler->isCoreFile($file)) ? 'application' : '' ?> call-stack-item"
data-line="<?= (int) ($line - $begin) ?>">
<div class="element-wrap">
<div class="element">
<span class="item-number"><?= (int) $index ?>.</span>
<span class="text"><?= $file !== null ? 'in ' . $handler->htmlEncode($file) : '' ?></span>
<span class="at">
<?= $line !== null ? 'at line' : '' ?>
<span class="line"><?= $line !== null ? $line + 1 : '' ?></span>
</span>
<?php if ($method !== null): ?>
<span class="call">
<?= $file !== null ? '&ndash;' : '' ?>
<?= ($class !== null ? $handler->addTypeLinks("$class::$method") : $handler->htmlEncode($method)) . '(' . $handler->argumentsToString($args) . ')' ?>
</span>
<?php endif; ?>
</div>
</div>
<?php if (!empty($lines)): ?>
<div class="code-wrap">
<div class="error-line"></div>
<?php for ($i = $begin; $i <= $end; ++$i): ?><div class="hover-line"></div><?php endfor; ?>
<div class="code">
<?php for ($i = $begin; $i <= $end; ++$i): ?><span class="lines-item"><?= (int) ($i + 1) ?></span><?php endfor; ?>
<pre>
<?php
// fill empty lines with a whitespace to avoid rendering problems in opera
for ($i = $begin; $i <= $end; ++$i) {
echo (trim($lines[$i]) === '') ? " \n" : strtr($handler->traceLine, ['{file}' => $file, '{line}' => $i + 1, '{html}' => $handler->htmlEncode($lines[$i])]);
}
?>
</pre>
</div>
</div>
<?php endif; ?>
</li>

View File

@@ -0,0 +1,90 @@
<?php
/* @var $exception \yii\web\HttpException|\Exception */
/* @var $handler \yii\web\ErrorHandler */
if ($exception instanceof \yii\web\HttpException) {
$code = $exception->statusCode;
} else {
$code = $exception->getCode();
}
$name = $handler->getExceptionName($exception);
if ($name === null) {
$name = 'Error';
}
if ($code) {
$name .= " (#$code)";
}
if ($exception instanceof \yii\base\UserException) {
$message = $exception->getMessage();
} else {
$message = 'An internal server error occurred.';
}
if (method_exists($this, 'beginPage')) {
$this->beginPage();
}
?>
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<title><?= $handler->htmlEncode($name) ?></title>
<style>
body {
font: normal 9pt "Verdana";
color: #000;
background: #fff;
}
h1 {
font: normal 18pt "Verdana";
color: #f00;
margin-bottom: .5em;
}
h2 {
font: normal 14pt "Verdana";
color: #800000;
margin-bottom: .5em;
}
h3 {
font: bold 11pt "Verdana";
}
p {
font: normal 9pt "Verdana";
color: #000;
}
.version {
color: gray;
font-size: 8pt;
border-top: 1px solid #aaa;
padding-top: 1em;
margin-bottom: 1em;
}
</style>
</head>
<body>
<h1><?= $handler->htmlEncode($name) ?></h1>
<h2><?= nl2br($handler->htmlEncode($message)) ?></h2>
<p>
The above error occurred while the Web server was processing your request.
</p>
<p>
Please contact us if you think this is a server error. Thank you.
</p>
<div class="version">
<?= date('Y-m-d H:i:s') ?>
</div>
<?php if (method_exists($this, 'endBody')): ?>
<?php $this->endBody() // to allow injecting code into body (mostly by Yii Debug Toolbar)?>
<?php endif ?>
</body>
</html>
<?php if (method_exists($this, 'endPage')): ?>
<?php $this->endPage() ?>
<?php endif ?>

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1,23 @@
<?php
/* @var $exception \yii\base\Exception */
/* @var $handler \yii\web\ErrorHandler */
?>
<div class="previous">
<span class="arrow">&crarr;</span>
<h2>
<span>Caused by:</span>
<?php $name = $handler->getExceptionName($exception) ?>
<?php if ($name !== null): ?>
<span><?= $handler->htmlEncode($name) ?></span> &ndash;
<?= $handler->addTypeLinks(get_class($exception)) ?>
<?php else: ?>
<span><?= $handler->htmlEncode(get_class($exception)) ?></span>
<?php endif; ?>
</h2>
<h3><?= nl2br($handler->htmlEncode($exception->getMessage())) ?></h3>
<p>in <span class="file"><?= $exception->getFile() ?></span> at line <span class="line"><?= $exception->getLine() ?></span></p>
<?php if ($exception instanceof \yii\db\Exception && !empty($exception->errorInfo)): ?>
<pre>Error Info: <?= $handler->htmlEncode(print_r($exception->errorInfo, true)) ?></pre>
<?php endif ?>
<?= $handler->renderPreviousExceptions($exception) ?>
</div>