Loading

New one-liner auth header

  1. ' Get the JSON response from MuddyBoots API and store the raw response in strJSONResponse
  2. Set objHTTP = Server.CreateObject("Msxml2.ServerXMLHTTP")
  3. objHTTP.open "GET",strMuddyBootsAPIURLFields,false,Session("GLUsername"), Session("GLPassword")
  4. objHTTP.setRequestHeader "Authorization", "Basic " & Base64Encode("" & Session("GLUsername") & ":" & Session("GLPassword") & "")
  5. objHTTP.send
  6. strJSONResponse = objHTTP.ResponseText

Comments

You'll also need to add in the Base64 encode function at http://pastebin.dg2.org/pzx9cj1hn

Rich • 09 Oct 2015, 13:54:20 UTC