View web pages on the command line

Is there a way to execute http GET / PUT / SET commands regardless of the command line in ubuntu or windows xp? Preferably without installing third-party products. Being that http is textual, I thought the cmd line would be easier to work with.

I was able to get what I want from GET to ubuntu in bash via

$wget google.com $cat index.html 

This is pretty awkward. It would be nice to blow the exit or something else, but even this is not straightforward. C programs are great too. I am trying to do something like what we get with Fiddler, but more basic.

+6
windows ubuntu
source share
3 answers
 telnet google.com 80 GET / HTTP/1.0 Host: google.com 

You must click twice twice after the Host line. It does not become more basic.

+6
source share

If you are familiar with using HTTP telnet .

If you are looking for a browser, find Links .

+3
source share

Although this requires a third-party tool, I use curl these days. The - X option allows me to specify an HTTP verb. There are several bash clients on Windows that let you run curl, including Cygwin .

Execution example

$ curl -H "Content-Type: application/json" -X POST -d '{value: "600"}' http://localhost:8888/my/endpoint

0
source share

All Articles