github.com/qxnw/lib4go@v0.0.0-20180426074627-c80c7e84b925/encoding/html/html.go (about)

     1  package html
     2  
     3  import (
     4  	"html"
     5  )
     6  
     7  // Encode html编码
     8  func Encode(input string) string {
     9  	return html.EscapeString(input)
    10  }
    11  
    12  // Decode html解码
    13  func Decode(input string) string {
    14  	return html.UnescapeString(input)
    15  }