示例#1
0
func (this *WeixinController) Post() {
	if ret, _ := weixin.CheckSignature(this.Ctx.ResponseWriter, this.Ctx.Request); ret == true {
		handleRequest(this.Ctx.ResponseWriter, this.Ctx.Request)
	} else {
		log.Println(this.Ctx.ResponseWriter, "invalid!")
	}
}
示例#2
0
func (this *WeixinController) Get() {
	if ret, echostr := weixin.CheckSignature(this.Ctx.ResponseWriter, this.Ctx.Request); ret == true {
		fmt.Fprintf(this.Ctx.ResponseWriter, echostr)
	} else {
		log.Println(this.Ctx.ResponseWriter, "invalid!")
	}
}