mirror of
https://github.com/mosbth/cimage.git
synced 2025-08-04 07:07:32 +02:00
code formatting and slightly reformatted verbose output
This commit is contained in:
@@ -23,7 +23,7 @@ function errorPage($msg)
|
|||||||
/**
|
/**
|
||||||
* Custom exception handler.
|
* Custom exception handler.
|
||||||
*/
|
*/
|
||||||
set_exception_handler(function($exception) {
|
set_exception_handler(function ($exception) {
|
||||||
errorPage("<p><b>img.php: Uncaught exception:</b> <p>" . $exception->getMessage() . "</p><pre>" . $exception->getTraceAsString(), "</pre>");
|
errorPage("<p><b>img.php: Uncaught exception:</b> <p>" . $exception->getMessage() . "</p><pre>" . $exception->getTraceAsString(), "</pre>");
|
||||||
});
|
});
|
||||||
|
|
||||||
@@ -380,11 +380,9 @@ if ($verbose) {
|
|||||||
unset($query['nocache']);
|
unset($query['nocache']);
|
||||||
unset($query['nc']);
|
unset($query['nc']);
|
||||||
$url1 = '?' . http_build_query($query);
|
$url1 = '?' . http_build_query($query);
|
||||||
$log = htmlentities(print_r(verbose(), 1));
|
|
||||||
echo <<<EOD
|
echo <<<EOD
|
||||||
<a href=$url1><code>$url1</code></a><br>
|
<a href=$url1><code>$url1</code></a><br>
|
||||||
<img src='{$url1}' />
|
<img src='{$url1}' />
|
||||||
<pre>$log</pre>
|
|
||||||
EOD;
|
EOD;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -398,6 +396,7 @@ require $config['cimage_class'];
|
|||||||
$img = new CImage();
|
$img = new CImage();
|
||||||
|
|
||||||
$img->setVerbose($verbose)
|
$img->setVerbose($verbose)
|
||||||
|
->log("Incoming arguments: " . print_r(verbose(), 1))
|
||||||
->setSource($srcImage, $config['image_path'])
|
->setSource($srcImage, $config['image_path'])
|
||||||
->setOptions(
|
->setOptions(
|
||||||
array(
|
array(
|
||||||
|
Reference in New Issue
Block a user