mirror of
https://github.com/vbatts/imgsrv.git
synced 2024-11-27 10:35:41 +00:00
tagging having a form upload for the client
This commit is contained in:
parent
ea2be195af
commit
1c14a76877
1 changed files with 13 additions and 0 deletions
|
@ -5,6 +5,7 @@ import (
|
||||||
"io/ioutil"
|
"io/ioutil"
|
||||||
"mime"
|
"mime"
|
||||||
"net/http"
|
"net/http"
|
||||||
|
"net/url"
|
||||||
"os"
|
"os"
|
||||||
"path/filepath"
|
"path/filepath"
|
||||||
)
|
)
|
||||||
|
@ -25,3 +26,15 @@ func PutFileFromPath(host, filename string) (path string, err error) {
|
||||||
}
|
}
|
||||||
return string(bytes), nil
|
return string(bytes), nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func hurr() {
|
||||||
|
values := make(url.Values)
|
||||||
|
values.Set("email", "anything@email.com")
|
||||||
|
values.Set("name", "bob")
|
||||||
|
values.Set("count", "1")
|
||||||
|
r, err := http.PostForm("http://example.com/form", values)
|
||||||
|
if err != nil {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
_ = r
|
||||||
|
}
|
||||||
|
|
Loading…
Reference in a new issue