Dim winHttp As Object
Set winHttp=CreateObject (" winHttp WinHttpRequest. 5.1 ")
With winHttp
. Open the "GET", GET_CONFIG_INFO_URL, False
The content-type. SetRequestHeader ", "" application/x - WWW - form - urlencoded"
End With
The winHttp. Send
If winHttp. Then Status=200
MsgBox "successful" & amp; The winHttp. The responseText
GetConfigJson=winHttp. The responseText
The Else
MsgBox "access failure" & amp; The winHttp. Status
End the If
Get request interfaces defined on the server side,
@ RequestMapping (value={} "/getconfiginfo", https://bbs.csdn.net/topics/method=RequestMethod. GET)
@ ResponseBody
Public String getconfiginfo () throws the Exception {
System. The out. Println (" getconfiginfo=====");
Return "configinfo is return";
}
Why the winHttp. The responseText return value has been empty for?" Receiving less than configinfo is return "?
CodePudding user response:
Get request interfaces defined on the server side,- please get request interface technology is through?
CodePudding user response:
The content-type. SetRequestHeader ", "" application/x - WWW - form - urlencoded" this line to delete the first look, the CONTENT TYPE is the time to POST, you interface with the GET now,