summaryrefslogtreecommitdiffstats
path: root/editversions.cgi
diff options
context:
space:
mode:
authorbbaetz%acm.org <>2003-11-22 12:50:36 +0100
committerbbaetz%acm.org <>2003-11-22 12:50:36 +0100
commitda857afa089e79ad16fb833dd1ffe397055fd892 (patch)
tree4582f630aa59c35fdb25aa30fd71c617977e0a86 /editversions.cgi
parent63790559f094b702688365ed12242526ce3ff969 (diff)
downloadbugzilla-da857afa089e79ad16fb833dd1ffe397055fd892.tar.gz
bugzilla-da857afa089e79ad16fb833dd1ffe397055fd892.tar.xz
Bug 208604 - Make data/template dir locations configurable
Diffstat (limited to 'editversions.cgi')
-rwxr-xr-xeditversions.cgi9
1 files changed, 4 insertions, 5 deletions
diff --git a/editversions.cgi b/editversions.cgi
index d47ec5d76..9c4a5e5ea 100755
--- a/editversions.cgi
+++ b/editversions.cgi
@@ -32,8 +32,7 @@ use lib ".";
require "CGI.pl";
require "globals.pl";
-
-
+use Bugzilla::Config qw(:DEFAULT $datadir);
# TestProduct: just returns if the specified product does exists
# CheckProduct: same check, optionally emit an error text
@@ -317,7 +316,7 @@ if ($action eq 'new') {
SqlQuote($version) . ", $product_id)");
# Make versioncache flush
- unlink "data/versioncache";
+ unlink "$datadir/versioncache";
print "OK, done.<p>\n";
PutTrailer("<A HREF=\"editversions.cgi?product=$product&amp;action=add\">add</a> another version or $localtrailer");
@@ -446,7 +445,7 @@ if ($action eq 'delete') {
print "Version deleted.<P>\n";
SendSQL("UNLOCK TABLES");
- unlink "data/versioncache";
+ unlink "$datadir/versioncache";
PutTrailer($localtrailer);
exit;
}
@@ -527,7 +526,7 @@ if ($action eq 'update') {
SET value=" . SqlQuote($version) . "
WHERE product_id = $product_id
AND value=" . SqlQuote($versionold));
- unlink "data/versioncache";
+ unlink "$datadir/versioncache";
print "Updated version.<BR>\n";
}
SendSQL("UNLOCK TABLES");