diff --git a/layouts/libraries/html/bootstrap/modal/main.php b/layouts/libraries/html/bootstrap/modal/main.php
index 666214c72849b..3cdbabb0e9ade 100644
--- a/layouts/libraries/html/bootstrap/modal/main.php
+++ b/layouts/libraries/html/bootstrap/modal/main.php
@@ -56,12 +56,12 @@
if (isset($params['backdrop']))
{
- $modalAttributes['data-backdrop'] = (is_bool($params['backdrop']) ? ($params['backdrop'] ? 'true' : 'false') : $params['backdrop']);
+ $modalAttributes['data-bs-backdrop'] = (is_bool($params['backdrop']) ? ($params['backdrop'] ? 'true' : 'false') : $params['backdrop']);
}
if (isset($params['keyboard']))
{
- $modalAttributes['data-keyboard'] = (is_bool($params['keyboard']) ? ($params['keyboard'] ? 'true' : 'false') : 'true');
+ $modalAttributes['data-bs-keyboard'] = (is_bool($params['keyboard']) ? ($params['keyboard'] ? 'true' : 'false') : 'true');
}
if (isset($params['url']))
diff --git a/libraries/src/HTML/Helpers/Bootstrap.php b/libraries/src/HTML/Helpers/Bootstrap.php
index ad29db0d197e3..63189e06ea2c2 100644
--- a/libraries/src/HTML/Helpers/Bootstrap.php
+++ b/libraries/src/HTML/Helpers/Bootstrap.php
@@ -282,7 +282,7 @@ public static function modal($selector = '', $options = []) :void
if ($selector !== '')
{
// Setup options object
- $opt['backdrop'] = isset($options['backdrop']) ? (bool) $options['backdrop'] : true;
+ $opt['backdrop'] = isset($options['backdrop']) ? $options['backdrop'] : false;
$opt['keyboard'] = isset($options['keyboard']) ? (bool) $options['keyboard'] : true;
$opt['focus'] = isset($options['focus']) ? (bool) $options['focus'] : true;