1
0
mirror of https://git.envs.net/envs/ifconfig synced 2024-11-22 09:51:57 +01:00

(*)no website switch in env variable

This commit is contained in:
Fan Yang 2015-12-27 18:53:43 +08:00
parent 32026b9c5c
commit cf627762cb

@ -5,6 +5,7 @@ import (
"fmt"
"github.com/astaxie/beego"
"net"
"os"
"strings"
)
@ -270,6 +271,10 @@ func (this *MainController) GetAllJSON() {
}
func (this *MainController) Get() {
if noweb := os.Getenv("NOWEB"); noweb == "1" {
this.Abort(404)
return
}
this.Data["Email"] = "missdeer@dfordsoft.com"
this.Data["UserAgent"] = this.Ctx.Request.UserAgent()
ip := this.Ctx.Input.IP()