From a120d14f175272da655d1fc70666f0f8e9b52b7f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Elan=20Ruusam=C3=A4e?= Date: Tue, 18 Sep 2012 22:57:31 +0200 Subject: [PATCH] wikiFN: allow retrieve attic path --- doku.php | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/doku.php b/doku.php index e27240e..b8af9a2 100755 --- a/doku.php +++ b/doku.php @@ -17,6 +17,9 @@ require_once DOKU_INC.'inc/init.php'; require_once DOKU_INC.'inc/common.php'; require_once DOKU_INC.'inc/cliopts.php'; +# disable gzip regardless of config, then we don't have to compress when converting +$conf['compression'] = 0; //compress old revisions: (0: off) ('gz': gnuzip) ('bz2': bzip) + function strip_dir($dir, $fn) { global $conf; return end(explode($dir.'/', $fn, 2)); @@ -27,7 +30,11 @@ case 'cleanID': echo cleanID($argv[2]); break; case 'wikiFN': - echo strip_dir($conf['datadir'], wikiFN($argv[2])); + if ($argc > 3) { + echo strip_dir($conf['olddir'], wikiFN($argv[2], $argv[3])); + } else { + echo strip_dir($conf['datadir'], wikiFN($argv[2])); + } break; case 'mediaFN': echo strip_dir($conf['mediadir'], mediaFN($argv[2]));