我正在使用牛仔(https://github.com/extend/cowboy)作为一项宁静的网络服务,我需要从“http://localhost:8080/?a=1&b=2&c=32”获取参数
init({tcp, http}, Req, Opts) ->
log4erl:debug("~p~n", [Opts]),
{ok, Req, undefined_state}.
handle(Req, State) ->
{ok, Req2} = cowboy_http_req:reply(200, [], <<"Hello World!">>, Req),
io:format("How to get the params from Req ? "),
{ok, Req2, State}.
terminate(Req, State) ->
log4erl:debug("~p~p~n", [Req, State]),
ok.