1
0
mirror of https://github.com/astaxie/beego.git synced 2025-07-04 09:40:19 +00:00

beego:query data from Form & params

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

View File

@ -211,6 +211,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()
}