mirror of
https://github.com/TiddlyWiki/TiddlyWiki5.git
synced 2026-04-29 12:56:42 +00:00
Move the editions into a subfolder
This commit is contained in:
26
editions/tw2/source/tiddlywiki/deprecated/Http.js
Executable file
26
editions/tw2/source/tiddlywiki/deprecated/Http.js
Executable file
@@ -0,0 +1,26 @@
|
||||
//--
|
||||
//-- Deprecated HTTP request code
|
||||
//-- Use the jQuery ajax functions directly instead
|
||||
//--
|
||||
|
||||
//# Load a file over http
|
||||
//# url - the source url
|
||||
//# callback - function to call when there is a response
|
||||
//# params - parameter object that gets passed to the callback for storing it's state
|
||||
//# Return value is the underlying XMLHttpRequest object, or a string if there was an error
|
||||
//# Callback function is called like this:
|
||||
//# callback(status,params,responseText,xhr)
|
||||
//# status - true if OK, false if error
|
||||
//# params - the parameter object provided to loadRemoteFile()
|
||||
//# responseText - the text of the file
|
||||
//# xhr - the underlying XMLHttpRequest object
|
||||
function loadRemoteFile(url,callback,params)
|
||||
{
|
||||
return httpReq("GET",url,callback,params);
|
||||
}
|
||||
|
||||
function doHttp(type,url,data,contentType,username,password,callback,params,headers,allowCache)
|
||||
{
|
||||
return httpReq(type,url,callback,params,headers,data,contentType,username,password,allowCache);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user