Tag: 查询参数

使用url_for查询参数?

url_for([:edit, @post]) 正在工作和生成/comments/123/edit 。 现在我需要添加一个查询参数,以便代替 /comments/123/edit 它是 /comments/123/edit?qp=asdf 我试过url_for([:edit, @post], :qp => “asdf”)但是没有去。