diff --git a/htdocs/bookmarks/card.php b/htdocs/bookmarks/card.php index 3a4ae51d62d..dcc6d8cdeab 100644 --- a/htdocs/bookmarks/card.php +++ b/htdocs/bookmarks/card.php @@ -98,7 +98,7 @@ if ($action == 'add' || $action == 'addproduct' || $action == 'update') if ($res > 0) { - if (empty($backtopage)) $backtopage=($urlsource?$urlsource:((! empty($url))?$url:DOL_URL_ROOT.'/bookmarks/list.php')); + if (empty($backtopage)) $backtopage=($urlsource?$urlsource:((! empty($url) && ! preg_match('/^http/i', $url))?$url:DOL_URL_ROOT.'/bookmarks/list.php')); header("Location: ".$backtopage); exit; } diff --git a/htdocs/bookmarks/list.php b/htdocs/bookmarks/list.php index 81205e4d6f8..0e22e2112cd 100644 --- a/htdocs/bookmarks/list.php +++ b/htdocs/bookmarks/list.php @@ -50,7 +50,7 @@ $pagenext = $page + 1; if (! $sortfield) $sortfield='position'; if (! $sortorder) $sortorder='ASC'; -$id = GETPOST("bid",'int'); +$id = GETPOST("id",'int'); /* @@ -179,11 +179,11 @@ if ($resql) print ''; if ($user->rights->bookmark->creer) { - print "bid."&backtopage=".urlencode($_SERVER["PHP_SELF"])."\">".img_edit()." "; + print "rowid."&backtopage=".urlencode($_SERVER["PHP_SELF"])."\">".img_edit()." "; } if ($user->rights->bookmark->supprimer) { - print "bid\">".img_delete().""; + print "rowid\">".img_delete().""; } else { @@ -209,7 +209,7 @@ print "
\n"; if ($user->rights->bookmark->creer) { - print ''.$langs->trans("NewBookmark").''; + print ''.$langs->trans("NewBookmark").''; } print '
';