chris-piekarski
7/16/2013 - 4:56 AM

Serve up html page from Go

Serve up html page from Go

func goHandler(w http.ResponseWriter, r *http.Request) {

     if r.Method  == "POST" {
          fmt.Print("Got a POST")
     }

     body, _ := ioutil.ReadFile("mag.html")
     w.Write(body)	
}