From c36ddb0f43f9e86bf06ba9b370b2549b49ef9f9c Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Wed, 16 Oct 2024 11:42:54 +0200 Subject: [PATCH] FIX dol_openinpopup for virtual card --- htdocs/main.inc.php | 6 +++--- htdocs/user/virtualcard.php | 4 +++- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/htdocs/main.inc.php b/htdocs/main.inc.php index 3437d79b2eb..7ab45ef8877 100644 --- a/htdocs/main.inc.php +++ b/htdocs/main.inc.php @@ -1639,7 +1639,7 @@ if (!function_exists("llxHeader")) { print ''."\n"; // top menu and left menu area - if ((empty($conf->dol_hide_topmenu) || GETPOSTINT('dol_invisible_topmenu')) && !GETPOSTINT('dol_openinpopup')) { + if ((empty($conf->dol_hide_topmenu) || GETPOSTINT('dol_invisible_topmenu')) && !GETPOST('dol_openinpopup', 'aZ09')) { top_menu($head, $title, $target, $disablejs, $disablehead, $arrayofjs, $arrayofcss, $morequerystring, $help_url); } @@ -3647,7 +3647,7 @@ function main_area($title = '') { global $conf, $langs, $hookmanager; - if (empty($conf->dol_hide_leftmenu) && !GETPOST('dol_openinpopup')) { + if (empty($conf->dol_hide_leftmenu) && !GETPOST('dol_openinpopup', 'aZ09')) { print '
'; } @@ -3902,7 +3902,7 @@ if (!function_exists("llxFooter")) { print '
'."\n"; // End div fiche - if (empty($conf->dol_hide_leftmenu) && !GETPOST('dol_openinpopup')) { + if (empty($conf->dol_hide_leftmenu) && !GETPOST('dol_openinpopup', 'aZ09')) { print ' '."\n"; // End div id-right } diff --git a/htdocs/user/virtualcard.php b/htdocs/user/virtualcard.php index 8e1da5deca2..d3e406f7ffb 100644 --- a/htdocs/user/virtualcard.php +++ b/htdocs/user/virtualcard.php @@ -134,7 +134,9 @@ print '
'; print '
'; $param = '&id='.((int) $object->id); -$param .= '&dol_openinpopup=1'; +if (GETPOSTISSET('dol_openinpopup')) { + $param .= '&dol_openinpopup='.urlencode(GETPOST('dol_openinpopup', 'aZ09')); +} $enabledisablehtml = $langs->trans("EnablePublicVirtualCard").' '; if (!getDolUserInt('USER_ENABLE_PUBLIC', 0, $object)) {