Rails: query parameter vs post parameter

前端 未结 4 658
闹比i
闹比i 2020-12-14 11:49

Suppose you have a url

localhost:3000?a=1

and in the request, you also have a post parameter

a=2

What wou

4条回答
  •  Happy的楠姐
    2020-12-14 12:45

    No it doesn't depend on de HTTP verb but you sure can have different actions to handle GET and POST or it can be the same and you'll get `params[:a] in both cases.

提交回复
热议问题