user3570103
user3570103

Reputation: 11

How to get and display the entire html url on screen through httpc: request in erlang?

do

process (Url) ->
  {Status, Header, Body} = httpc:request(get, {Url, []}, [], []),
 io:format(Body).

no output html to Body to display

how to get and display the entire html url on screen through httpc:request in erlang?

Upvotes: 1

Views: 69

Answers (1)

fenollp
fenollp

Reputation: 2496

io:format/2 works kind of like C's printf: you need a format string.

io:format("Body: ~p\n", [Body]).

Documentation

Upvotes: 1

Related Questions