1
0
mirror of https://github.com/astaxie/beego.git synced 2025-06-12 12:50:40 +00:00

beego:query data from Form & params

This commit is contained in:
astaxie
2014-04-10 22:20:46 +08:00
parent e50cbecf80
commit b212ec8dab
2 changed files with 8 additions and 8 deletions

View File

@ -212,6 +212,9 @@ func (input *BeegoInput) Param(key string) string {
// Query returns input data item string by a given string.
func (input *BeegoInput) Query(key string) string {
if val := input.Param(key); val != "" {
return val
}
if input.Request.Form == nil {
input.Request.ParseForm()
}