FIX - 10.0 - regex to remove 'action' parameter: taking feedback from PR#15213 into account

This commit is contained in:
Florian Mortgat 2020-11-02 08:26:36 +01:00
parent 5e2962ef38
commit 400acf9f65

View File

@ -83,7 +83,7 @@ $(document).ready(function(){
<?php
$redirectURL = empty($urltorefreshaftermove) ? ($_SERVER['PHP_SELF'].'?'.dol_escape_js($_SERVER['QUERY_STRING'])) : $urltorefreshaftermove;
// remove action parameter from URL
$redirectURL = preg_replace('/[&?]action=[^&]*/', '', $redirectURL);
$redirectURL = preg_replace('/(&|\?)action=[^&#]*/', '', $redirectURL);
?>
location.href = '<?php echo dol_escape_js($redirectURL); ?>';
} else {