github.com/gogf/gf@v1.16.9/.example/net/ghttp/server/ports.go (about) 1 package main 2 3 import ( 4 "github.com/gogf/gf/net/ghttp" 5 ) 6 7 func main() { 8 s := ghttp.GetServer() 9 s.BindHandler("/", func(r *ghttp.Request) { 10 r.Response.Writeln("go frame!") 11 }) 12 s.SetPort(8100, 8200, 8300) 13 s.Run() 14 }