018-Go将磁盘目录实现简单的静态Web服务
package main
import(
"net/http"
)
func main(){
http.Handle("/", http.FileServer(http.Dir("D:/web/AmazeUI-2.7.2/")))
http.ListenAndServe(":8080", nil)
}
package main
import(
"net/http"
)
func main(){
http.Handle("/", http.FileServer(http.Dir("D:/web/AmazeUI-2.7.2/")))
http.ListenAndServe(":8080", nil)
}