ES2Web.Delete
Description
Deletes data from the database at the given URL.
C#
Deletes data from the server with the given tag
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 |
// Coroutine which deletes data with a given tag from our server. public IEnumerator DeleteTag(string tag) { string myURL = "https://www.server.com/ES2.php?webfilename=myFile.txt"; ES2Web web = new ES2Web(myURL + "&tag=" + tag); // Send request to delete our data and wait for it to finish. yield return StartCoroutine(web.Delete()); if(web.isError) { // Enter your own code to handle errors here. // For a list of error codes, see www.moodkie.com/easysave/ES2Web.ErrorCodes.php Debug.LogError(web.errorCode + ":" + web.error); } } |
JS
Deletes data from the server with the given tag
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 |
// Coroutine which deletes data with a given tag from our server. public IEnumerator DeleteTag(string tag) { string myURL = "https://www.server.com/ES2.php?webfilename=myFile.txt"; ES2Web web = new ES2Web(myURL + "&tag=" + tag); // Send request to delete our data and wait for it to finish. yield return StartCoroutine(web.Delete()); if(web.isError) { // Enter your own code to handle errors here. // For a list of error codes, see www.moodkie.com/easysave/ES2Web.ErrorCodes.php Debug.LogError(web.errorCode + ":" + web.error); } } |