Do not use ch.DNSName

This commit is contained in:
2022-03-14 07:05:38 +09:00
parent 9a7e0ef027
commit fb99ace026
2 changed files with 17 additions and 13 deletions

View File

@@ -34,6 +34,12 @@ const URI_DELETE_RECORD = "https://freedns.afraid.org/subdomain/delete2.php?data
// const URI_LOGIN string = "http://127.0.0.1:1234/"
func GetDomainFromZone(Zone string) string {
_segs := strings.Split(Zone, ".")
_segs = _segs[len(_segs)-2:]
return strings.Join(_segs, ".")
}
func _HttpRequest(method string, url string, PostData url.Values, ExCookie *http.Cookie) (*http.Response, string, error) {
client := http.Client{
CheckRedirect: func(req *http.Request, via []*http.Request) error {