Go的Web版

package main

import "net/http"

func f1(a http.ResponseWriter, b *http.Request) {
    str := "<H1>Hello Dzw!</H1>"
    a.Write([]byte(str))
}

func main() {

    http.HandleFunc("/dzw/Test01", f1)
    http.ListenAndServe("127.0.0.1:9090", nil)

}

结果:

 

 参考:https://www.bilibili.com/video/BV1fz4y1m7Pm?p=120

 

posted @ 2021-06-29 16:32  蜗牛的礼物  阅读(31)  评论(0编辑  收藏  举报