Browse Source

增加发送xml

master v0.4.1
guzeng 2 years ago
parent
commit
2589808f45
1 changed files with 3 additions and 1 deletions
  1. +3
    -1
      http.go

+ 3
- 1
http.go View File

@ -1,6 +1,8 @@
package network
import (
"bytes"
"encoding/xml"
"io/ioutil"
"net/http"
"strings"
@ -97,7 +99,7 @@ func SendXml(method, url string, requestxml interface{}, header ...map[string]st
httpClient := &http.Client{}
req, err := http.NewRequest(method, url, bytes.NewBuffer(param))
req, err := http.NewRequest(method, url, bytes.NewBuffer(bytexml))
if err != nil {
return []byte(""), err
}


Loading…
Cancel
Save