Update README.md

This commit is contained in:
Alex Cornford 2017-03-24 13:56:39 -04:00 committed by GitHub
parent e2212d40c6
commit c19da25a21

View File

@ -1,5 +1,5 @@
#Gin Web Framework # Gin Web Framework
<img align="right" src="https://raw.githubusercontent.com/gin-gonic/gin/master/logo.jpg"> <img align="right" src="https://raw.githubusercontent.com/gin-gonic/gin/master/logo.jpg">
[![Build Status](https://travis-ci.org/gin-gonic/gin.svg)](https://travis-ci.org/gin-gonic/gin) [![Build Status](https://travis-ci.org/gin-gonic/gin.svg)](https://travis-ci.org/gin-gonic/gin)
@ -133,7 +133,7 @@ func main() {
func main() { func main() {
router := gin.Default() router := gin.Default()
// This handler will match /user/john but will not match neither /user/ or /user // This handler will match /user/john but will not match /user/ or /user
router.GET("/user/:name", func(c *gin.Context) { router.GET("/user/:name", func(c *gin.Context) {
name := c.Param("name") name := c.Param("name")
c.String(http.StatusOK, "Hello %s", name) c.String(http.StatusOK, "Hello %s", name)
@ -372,7 +372,7 @@ func main() {
``` ```
###Multipart/Urlencoded binding ### Multipart/Urlencoded binding
```go ```go
package main package main
@ -450,7 +450,7 @@ func main() {
} }
``` ```
####Serving static files #### Serving static files
```go ```go
func main() { func main() {
@ -464,7 +464,7 @@ func main() {
} }
``` ```
####HTML rendering #### HTML rendering
Using LoadHTMLTemplates() Using LoadHTMLTemplates()