Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Fetching contributors…

Cannot retrieve contributors at this time

22 lines (18 sloc) 0.656 kB
-module(reentranttest).
-export([out/1]).
-include("../../include/yaws.hrl").
-include("../../include/yaws_api.hrl").
out(Arg) ->
Url = yaws_api:request_url(Arg),
case Url#url.path of
"/reentranttest/status" ->
{page, {[{status, 201}], "/hello.txt"}};
"/reentranttest/delayed_headers" ->
Hdrs = [{header, {cache_control, "no-cache"}},
{header, "Etag: static-tag"},
{header, "X-Delayed-Header: true"}],
{page, {Hdrs, "/hello.txt"}};
_ ->
Reason = "unknown path: " ++ Url#url.path,
[{status, 500}, {html, Reason}]
end.
Jump to Line
Something went wrong with that request. Please try again.