Changed the way the comment is handled :
* If the comment is HTML just replace <br> -> </br /> * Else adapt the comment to html Should fix #2
This commit is contained in:
parent
9cac9980c1
commit
cd6bf1c1cf
9
book.php
9
book.php
|
@ -123,7 +123,14 @@ class Book extends Base {
|
|||
if (!is_null ($se)) {
|
||||
$addition = $addition . "<strong>" . localize("content.series") . "</strong>" . str_format (localize ("content.series.data"), $this->seriesIndex, $se->name) . "<br />\n";
|
||||
}
|
||||
return $addition . strip_tags ($this->comment, '<div>');
|
||||
if (preg_match ("/<\/(div|p)>/", $this->comment))
|
||||
{
|
||||
return $addition . str_replace ("<br>", "<br />", $this->comment);
|
||||
}
|
||||
else
|
||||
{
|
||||
return $addition . htmlspecialchars ($this->comment);
|
||||
}
|
||||
}
|
||||
|
||||
public function getFilePath ($extension, $relative = false)
|
||||
|
|
Loading…
Reference in a new issue