Xbase++ Requires Chilkat v11.0.0+
Xbase++
Transition from Http.QuickPutStr to Http.HttpNoBody
Provides instructions for replacing deprecated QuickPutStr method calls with HttpNoBody.Chilkat Xbase++ Downloads
LOCAL nSuccess
LOCAL oHttp
LOCAL cUrl
LOCAL cResponseBody
LOCAL oResponseOut
nSuccess := 0
oHttp := CreateObject("Chilkat.Http")
// ...
// ...
cUrl := "https://example.com/test"
// ------------------------------------------------------------------------
// The QuickPutStr method is deprecated:
cResponseBody := oHttp:QuickPutStr(cUrl)
IF (oHttp:LastMethodSuccess == 0)
? oHttp:LastErrorText
oHttp:destroy()
RETURN
ENDIF
// ...
// ...
// ------------------------------------------------------------------------
// Do the equivalent using HttpNoBody.
// Your application creates a new, empty HttpResponse object which is passed
// in the last argument and filled upon success.
oResponseOut := CreateObject("Chilkat.HttpResponse")
nSuccess := oHttp:HttpNoBody("PUT", cUrl, oResponseOut)
IF (nSuccess == 0)
? oHttp:LastErrorText
oHttp:destroy()
oResponseOut:destroy()
RETURN
ENDIF
cResponseBody := oResponseOut:BodyStr
oHttp:destroy()
oResponseOut:destroy()