mirror of
https://github.com/phpbb/phpbb.git
synced 2025-08-02 14:57:37 +02:00
Merge pull request #4072 from marc1706/ticket/14344
[ticket/14344] Improve output of HTML errors trigged during install * marc1706/ticket/14344: [ticket/14344] Improve output of HTML errors trigged during install
This commit is contained in:
@@ -125,6 +125,10 @@ class cli_iohandler extends iohandler_base
|
|||||||
{
|
{
|
||||||
$this->io->newLine();
|
$this->io->newLine();
|
||||||
|
|
||||||
|
if (strpos($error_title, '<br />') !== false)
|
||||||
|
{
|
||||||
|
$error_title = strip_tags(str_replace('<br />', "\n", $error_title));
|
||||||
|
}
|
||||||
$message = $this->translate_message($error_title, $error_description);
|
$message = $this->translate_message($error_title, $error_description);
|
||||||
$message_string = $message['title'] . (!empty($message['description']) ? "\n" . $message['description'] : '');
|
$message_string = $message['title'] . (!empty($message['description']) ? "\n" . $message['description'] : '');
|
||||||
$this->io->error($message_string);
|
$this->io->error($message_string);
|
||||||
|
@@ -101,6 +101,10 @@ abstract class iohandler_base implements iohandler_interface
|
|||||||
*/
|
*/
|
||||||
public function add_error_message($error_title, $error_description = false)
|
public function add_error_message($error_title, $error_description = false)
|
||||||
{
|
{
|
||||||
|
if (strpos($error_title, '<br />') !== false)
|
||||||
|
{
|
||||||
|
$error_title = strip_tags(htmlspecialchars_decode($error_title));
|
||||||
|
}
|
||||||
$this->errors[] = $this->translate_message($error_title, $error_description);
|
$this->errors[] = $this->translate_message($error_title, $error_description);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user