From 2d051c6786b24621c48d646952b69ee5e0936ff7 Mon Sep 17 00:00:00 2001 From: Alexander Walther Date: Mon, 8 Jan 2024 14:20:27 +0100 Subject: [PATCH] warning_intro (#1462) --- lib/yform.php | 1 + ytemplates/bootstrap/errors.tpl.php | 5 ++++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/lib/yform.php b/lib/yform.php index 6c86bc5ea..c0e7d8417 100644 --- a/lib/yform.php +++ b/lib/yform.php @@ -85,6 +85,7 @@ public function __construct(array $params = []) $this->objparams['form_hiddenfields'] = []; $this->objparams['warning'] = []; + $this->objparams['warning_intro'] = ''; $this->objparams['warning_messages'] = []; $this->objparams['hide_top_warning_messages'] = false; diff --git a/ytemplates/bootstrap/errors.tpl.php b/ytemplates/bootstrap/errors.tpl.php index f83b12905..4a91eed0f 100644 --- a/ytemplates/bootstrap/errors.tpl.php +++ b/ytemplates/bootstrap/errors.tpl.php @@ -9,7 +9,10 @@ objparams['warning_messages'] || $this->objparams['unique_error']): - if ($this->objparams['Error-occured']): ?> + if ($this->objparams['Error-occured']): + if($this->objparams['warning_intro']) { ?> +

objparams['warning_intro'] ?>

+
objparams['Error-occured'] ?>