【发布时间】:2012-10-04 15:52:50
【问题描述】:
我在 rails 3.2 应用程序中有一个 js.erb 文件,该文件使用 url 帮助程序在 jquery $.ajax 调用中填写 url 字段。当我在本地机器上使用正确指向 localhost:3000/path_to_method 的 path_to_method_url/path 时,它工作正常。当我将它放在具有子 uri 的暂存环境中时,它指向 example-staging.com/path_to_method 而不是 example-staging.com/sub-uri/path_to_method。有人知道如何让资产中的 url 助手尊重子 uri 吗?
【问题讨论】:
标签: ruby-on-rails