|
From: <var...@us...> - 2021-06-21 14:10:17
|
Revision: 10307
http://sourceforge.net/p/phpwiki/code/10307
Author: vargenau
Date: 2021-06-21 14:10:17 +0000 (Mon, 21 Jun 2021)
Log Message:
-----------
lib/plugin/TeX2png.php: add class "error"
Modified Paths:
--------------
trunk/lib/plugin/TeX2png.php
Modified: trunk/lib/plugin/TeX2png.php
===================================================================
--- trunk/lib/plugin/TeX2png.php 2021-06-21 14:00:15 UTC (rev 10306)
+++ trunk/lib/plugin/TeX2png.php 2021-06-21 14:10:17 UTC (rev 10307)
@@ -224,16 +224,19 @@
// if imagepath does not exist, try to create it
if (!file_exists($this->imagepath)) {
if (mkdir($this->imagepath, 0777, true) === false) {
- return HTML::p(fmt("Cannot create directory “%s”", $this->imagepath));
+ return HTML::span(array('class' => 'error'),
+ fmt("Cannot create directory “%s”", $this->imagepath));
}
}
// imagepath exists, check is a directory and is writable
if (!is_dir($this->imagepath)) {
- return HTML::p(fmt("“%s” must be a directory", $this->imagepath));
+ return HTML::span(array('class' => 'error'),
+ fmt("“%s” must be a directory", $this->imagepath));
}
if (!is_writable($this->imagepath)) {
- return HTML::p(fmt("“%s” must be a writable", $this->imagepath));
+ return HTML::span(array('class' => 'error'),
+ fmt("“%s” must be a writable", $this->imagepath));
}
// from text2png.php
@@ -246,7 +249,7 @@
$error_html = _("Sorry, this version of PHP cannot create PNG image files.");
$link = "http://www.php.net/manual/pl/ref.image.php";
$error_html .= sprintf(_("See %s"), $link) . ".";
- return HTML::p($error_html);
+ return HTML::p(array('class' => 'error'), $error_html);
}
}
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|