From 16e17a8328ea7d0ecd0ae6959127719276c6aa21 Mon Sep 17 00:00:00 2001 From: Robert Sesek Date: Mon, 16 Jan 2006 08:14:30 +0000 Subject: [PATCH] r744: Add an optional location to bounce back to with cancel --- templates/editattach.tpl | 2 +- templates/editcomment.tpl | 2 +- templates/global.js | 5 +++-- templates/newattach.tpl | 2 +- 4 files changed, 6 insertions(+), 5 deletions(-) diff --git a/templates/editattach.tpl b/templates/editattach.tpl index 5eb98f8..e0685c7 100644 --- a/templates/editattach.tpl +++ b/templates/editattach.tpl @@ -35,7 +35,7 @@ $header
- +
diff --git a/templates/editcomment.tpl b/templates/editcomment.tpl index e3abeb7..b0e1f5a 100644 --- a/templates/editcomment.tpl +++ b/templates/editcomment.tpl @@ -39,7 +39,7 @@ $header
- +
$footer \ No newline at end of file diff --git a/templates/global.js b/templates/global.js index 139e26b..26709a0 100644 --- a/templates/global.js +++ b/templates/global.js @@ -9,9 +9,10 @@ || ################################################################### || \*=====================================================================*/ -function draw_cancel() +function draw_cancel(location) { - document.write(''); + location = (location == "" ? "history.back(1)" : "window.location='" + location + "'"); + document.write(''); } /*=====================================================================*\ diff --git a/templates/newattach.tpl b/templates/newattach.tpl index e904189..5d0f4a0 100644 --- a/templates/newattach.tpl +++ b/templates/newattach.tpl @@ -55,7 +55,7 @@ $header
- +
-- 2.22.5