pp_projekt/calendar/controller.go
2018-12-02 19:22:59 +01:00

23 lines
396 B
Go

package calendar
import (
"fmt"
"net/http"
)
func AddCalendar(w http.ResponseWriter, r *http.Request) {
keys, ok := r.URL.Query()["key"]
if !ok || len(keys[0]) < 1 {
fmt.Println("Url Param 'key' is missing")
return
}
key := keys[0]
fmt.Fprint(w, "Url Param 'key' is: " + string (key))
}
//func Calendar(w http.ResponseWriter, r *http.Request) {
// fmt.Fprint(w, "Welcome!\n")
//}