From 61f6828d123080017b01e322eea19eb3707da428 Mon Sep 17 00:00:00 2001 From: Owen Leonard Date: Fri, 11 Feb 2011 01:08:19 -0500 Subject: [PATCH] Follow-up fix for Bug 5733 - Empty cart in intranet when session is closed Modifying empty cart function to take a paramter: if true, cart will be emptied without a prompt. Removing unnecessary "javascript:" pseudo-protocol. Signed-off-by: Nicole Engard Signed-off-by: Chris Cormack --- koha-tmpl/intranet-tmpl/prog/en/includes/header.inc | 2 +- koha-tmpl/intranet-tmpl/prog/en/js/basket.js | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/header.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/header.inc index b830e62950..ea556c4d3f 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/includes/header.inc +++ b/koha-tmpl/intranet-tmpl/prog/en/includes/header.inc @@ -64,7 +64,7 @@ - ( onclick="javascript:delBasket(true);">Log Out) | + ( onclick="delBasket(true);">Log Out) | You are not logged in | diff --git a/koha-tmpl/intranet-tmpl/prog/en/js/basket.js b/koha-tmpl/intranet-tmpl/prog/en/js/basket.js index 0ab67113cc..9946cf752c 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/js/basket.js +++ b/koha-tmpl/intranet-tmpl/prog/en/js/basket.js @@ -299,10 +299,10 @@ function delRecord (n, s) { } -function delBasket() { - - var rep = false; - rep = confirm(MSG_CONFIRM_DEL_BASKET); +function delBasket(rep) { + if (rep == undefined){ + rep = confirm(MSG_CONFIRM_DEL_BASKET); + } if (rep) { delCookie(nameCookie); document.location = "about:blank"; -- 2.39.5