daily pastebin goal
10%
SHARE
TWEET

Untitled

a guest Jul 11th, 2018 64 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. FreshBooks_HttpClient.prototype.sendRequest = function(content)
  2. {
  3.     Mojo.Log.error("Sending Request");
  4.     Mojo.Log.error("Content: %s", content);
  5.     var post = "token=" + this.token + "&content=" + content;
  6.     Mojo.Log.info("POST: %s", post);
  7.     this.request.open("POST", this.url, false, this.token);
  8.     this.request.setRequestHeader("Content-type", "application/x-www-form-urlencoded");
  9.     this.request.setRequestHeader("Content-length", post.length);
  10.     this.request.send(post);
  11.     if(this.request.status == 200)
  12.     {
  13.         Mojo.Log.error("Response: %j", this.request);
  14.         return this.request.responseXML;
  15.     }
  16.     else
  17.     {
  18.         return false;
  19.     }
  20. };
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top