mirror of
https://github.com/processone/ejabberd.git
synced 2024-11-22 16:20:52 +01:00
Minor changes (thanks to Stefan Strigler)
SVN Revision: 2269
This commit is contained in:
parent
bb229a3a0c
commit
197639a34b
File diff suppressed because it is too large
Load Diff
@ -3,7 +3,6 @@
|
||||
%%% Author : Stefan Strigler <steve@zeank.in-berlin.de>
|
||||
%%% Purpose : Implementation of XMPP over BOSH (XEP-0206)
|
||||
%%% Created : Tue Feb 20 13:15:52 CET 2007
|
||||
%%% Id : $Id: $
|
||||
%%%----------------------------------------------------------------------
|
||||
|
||||
%%%----------------------------------------------------------------------
|
||||
@ -15,7 +14,7 @@
|
||||
-module(mod_http_bind).
|
||||
-author('steve@zeank.in-berlin.de').
|
||||
|
||||
-define(MOD_HTTP_BIND_VERSION, "1.0").
|
||||
-define(MOD_HTTP_BIND_VERSION, '1.0').
|
||||
-vsn(?MOD_HTTP_BIND_VERSION).
|
||||
|
||||
%%-define(ejabberd_debug, true).
|
||||
@ -48,7 +47,7 @@ process([], #request{method = 'POST',
|
||||
ejabberd_http_bind:process_request(Data);
|
||||
process([], #request{method = 'GET',
|
||||
data = []}) ->
|
||||
Heading = "Ejabberd " ++ atom_to_list(?MODULE) ++ " v" ++ ?MOD_HTTP_BIND_VERSION,
|
||||
Heading = "Ejabberd " ++ atom_to_list(?MODULE) ++ " v" ++ lists:concat([?MOD_HTTP_BIND_VERSION]),
|
||||
{xmlelement, "html", [{"xmlns", "http://www.w3.org/1999/xhtml"}],
|
||||
[{xmlelement, "head", [],
|
||||
[{xmlelement, "title", [], [{xmlcdata, Heading}]}]},
|
||||
@ -57,21 +56,16 @@ process([], #request{method = 'GET',
|
||||
{xmlelement, "p", [],
|
||||
[{xmlcdata, "An implementation of "},
|
||||
{xmlelement, "a", [{"href", "http://www.xmpp.org/extensions/xep-0206.html"}],
|
||||
[{xmlcdata, "XMPP over BOSH (XEP-0206)"}]}]},
|
||||
[{xmlcdata, "XMPP over BOSH (XEP-0206)"}]},
|
||||
{xmlcdata, "."}]},
|
||||
{xmlelement, "p", [],
|
||||
[{xmlcdata, integer_to_list(mnesia:table_info(http_bind, size)) ++ " sessions found."}]},
|
||||
{xmlelement, "p", [],
|
||||
[{xmlcdata, "Sponsored by "},
|
||||
{xmlelement, "a", [{"href", "http://mabber.com"}],
|
||||
[{xmlcdata, "mabber"}]},
|
||||
{xmlcdata, "."}]}
|
||||
]}]};
|
||||
[{xmlcdata, integer_to_list(mnesia:table_info(http_bind, size)) ++ " sessions found."}]}
|
||||
]}]};
|
||||
process(_Path, _Request) ->
|
||||
?DEBUG("Bad Request: ~p", [_Request]),
|
||||
{400, [], {xmlelement, "h1", [],
|
||||
[{xmlcdata, "400 Bad Request"}]}}.
|
||||
|
||||
|
||||
%%%----------------------------------------------------------------------
|
||||
%%% BEHAVIOUR CALLBACKS
|
||||
%%%----------------------------------------------------------------------
|
||||
|
Loading…
Reference in New Issue
Block a user