summaryrefslogtreecommitdiff
path: root/src/web/ejabberd_web_admin.erl
diff options
context:
space:
mode:
authorBadlop <badlop@process-one.net>2009-01-20 19:42:08 +0000
committerBadlop <badlop@process-one.net>2009-01-20 19:42:08 +0000
commit3e2048ace95f8b80ce43d77898f12f058b112e8b (patch)
tree45579888a7c6bd18700a57dc32aacce4187a05ad /src/web/ejabberd_web_admin.erl
parent* src/mod_privacy.erl: Only run roster_get_jid_info if privacy (diff)
* src/Makefile.in: The path to the installed copy of ejabberd
Guide is set in the environment variable EJABBERD_DOC_PATH (EJAB-837). * src/web/ejabberd_web_admin.erl: Likewise * src/ejabberdctl.template: Likewise * doc/guide.tex: Likewise * doc/guide.html: Likewise SVN Revision: 1835
Diffstat (limited to 'src/web/ejabberd_web_admin.erl')
-rw-r--r--src/web/ejabberd_web_admin.erl8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/web/ejabberd_web_admin.erl b/src/web/ejabberd_web_admin.erl
index ea1a936e..83298391 100644
--- a/src/web/ejabberd_web_admin.erl
+++ b/src/web/ejabberd_web_admin.erl
@@ -41,9 +41,9 @@
process(["doc", LocalFile], _Request) ->
- DocPath = case ejabberd_config:get_global_option(doc_path) of
+ DocPath = case os:getenv("EJABBERD_DOC_PATH") of
P when is_list(P) -> P;
- _ -> "/share/doc/ejabberd/"
+ false -> "/share/doc/ejabberd/"
end,
%% Code based in mod_http_fileserver
FileName = filename:join(DocPath, LocalFile),
@@ -55,8 +55,8 @@ process(["doc", LocalFile], _Request) ->
FileContents};
{error, Error} ->
?DEBUG("Delivering error: ~p", [Error]),
- Help = " " ++ FileName ++ " - Try to specify the path to ejabberd guide.html "
- "with the option doc_path. Check the ejabberd Guide for more information",
+ Help = " " ++ FileName ++ " - Try to specify the path to ejabberd documentation "
+ "with the environment variable EJABBERD_DOC_PATH. Check the ejabberd Guide for more information.",
case Error of
eacces -> {403, [], "Forbidden"++Help};
enoent -> {404, [], "Not found"++Help};