2019-06-02から1日間の記事一覧
Goでnet/httpを用いて簡単なWebサーバを作ります。 package main import ( "html/template" "io/ioutil" "log" "net/http" "regexp" ) type Page struct { Title string Body []byte } func (p *Page) save() error { filename := p.Title + ".txt" return i…
Goでnet/httpを用いて簡単なWebサーバを作ります。 package main import ( "html/template" "io/ioutil" "log" "net/http" "regexp" ) type Page struct { Title string Body []byte } func (p *Page) save() error { filename := p.Title + ".txt" return i…