Learn R Programming

httpRequest (version 0.0.3)

GetToHost: Sends Get Request to HTTP Server (host)

Description

Sends Get Request to HTTP Server

Usage

GetToHost(host,path,referer,port=80)

Arguments

host
The host to which to send the Request eg.: www.spiegel.de, 127.0.01
path
The path to the file eg. /cgi/getpasswords.pl?test=best or /index.html
referer
something like www.myhome.org
port
its 80 or 8080 most frequently

Value

  • The document which the server returns as a string.

Details

It is a simple http client. So it does not take care of special chars e.g. whitspaces. For details see e.g. perl HTTP::Request::Common documentation. and http://www.w3.org/Protocols/rfc1341/0_TableOfContents.html

Examples

Run this code
#GetToHost("www.spiegel.de","index.html","www.test.pl",port=port)

#for sample code look in the help directory of the package

Run the code above in your browser using DataLab