pb 调用http 接口问题,返回值JSON格式,怎么获取返回值

如题所述

第1个回答  2017-05-10
Blob lblb_args
String ls_header
String ls_url
String ls_args
long ll_length
integer li_rc

li_rc = GetContextService( "Internet", iinet_base )
IF li_rc = 1 THEN
iinet = Create n_iinet
ir = CREATE n_ir_msgbox
ls_url = "http://125.64.14.211:89/gpsonline/GPSAPI?"
ls_args = "version=1&method=loginSystem&name=hds&pwd=666888"
lblb_args = Blob( ls_args )
ll_length = Len( lblb_args )
ls_header = "Content-Type: " + &
"application/x-www-form-urlencoded~n" + &
"Content-Length: " + String( ll_length ) + "~n~n"
li_rc = iinet.PostURL( ls_url, lblb_args, ls_header, ir )

END IF