예제 #1
0
func GetFlash(w http.ResponseWriter, r *http.Request) (string, string) {
	msg := strings.Split(cook.Get(r, "flash"), ":")
	cook.Delete(w, r, "flash")
	if len(msg) != 2 {
		return "", ""
	}
	return msg[0], msg[1]
}
예제 #2
0
func Logout(w http.ResponseWriter, r *http.Request) {
	cook.Delete(w, r, "SESS-D")
}
예제 #3
0
func DelCook(w http.ResponseWriter, r *http.Request) {
	cook.Delete(w, r, r.FormValue("cook"))
	http.Redirect(w, r, "/getall", 303)
	return
}