Difference between revisions of "Http.get"
From ComputerCraft Wiki
(anh con may cung voi coi nha) |
|||
Line 1: | Line 1: | ||
− | + | {{lowercase}} | |
+ | {{Function | ||
+ | |name=http.get | ||
+ | |args=[[string]] url | ||
+ | |api=HTTP | ||
+ | |returns=The response of the server or nil on failure. | ||
+ | |addon=ComputerCraft | ||
+ | |examples= | ||
+ | ===Basic usage=== | ||
+ | {{Example | ||
+ | |desc=Gets the content of example.com (in HTML) | ||
+ | |code=local sExample = http.get("http://example.com/")<br />write(sExample) | ||
+ | |output=The source of example.com | ||
+ | }} | ||
+ | }} |
Revision as of 10:45, 24 June 2012
Function http.get | |
No description provided. | |
Syntax | http.get(string url) |
Returns | The response of the server or nil on failure. |
Part of | ComputerCraft |
API | HTTP |
Examples
Basic usage
Example | |
Gets the content of example.com (in HTML) | |
Code |
local sExample = http.get("http://example.com/") |
Output | The source of example.com |