Commit 677ffce0 by Joneq

修改ip的访问

parent 6f9bea3a
Showing with 5 additions and 5 deletions
package main package main
import "kaopu-server/internal/logic" import "fmt"
func main() { func main() {
logic.NetBasicHttpGet(logic.COMPANYINFOURL,"深圳市禾田普达科技有限公司") fmt.Print(1)
} }
......
...@@ -118,7 +118,7 @@ func HttpGet(companyName string)(returnDatas map[string]string) { ...@@ -118,7 +118,7 @@ func HttpGet(companyName string)(returnDatas map[string]string) {
return returnData return returnData
} }
func BasicHttpGet(url,name string)(respBody []byte) { func NetBasicHttpGet(url,name string)(respBody []byte) {
req, err := http.NewRequest("GET", url, nil) req, err := http.NewRequest("GET", url, nil)
...@@ -139,9 +139,9 @@ func BasicHttpGet(url,name string)(respBody []byte) { ...@@ -139,9 +139,9 @@ func BasicHttpGet(url,name string)(respBody []byte) {
} }
//内网访问 //内网访问
func NetBasicHttpGet(url,name string)(respBody []byte) { func BasicHttpGet(url,name string)(respBody []byte) {
req, err := http.NewRequest("GET", "http://localhost/tyc_turn.php", nil) req, err := http.NewRequest("GET", "http://172.18.137.21/tyc_turn.php", nil)
q := req.URL.Query() q := req.URL.Query()
q.Add("pageNum","1") q.Add("pageNum","1")
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment