【发布时间】:2013-05-21 08:47:32
【问题描述】:
subdomain-fu gem 中的 tld_size 是什么意思。例如聋哑人,
SubdomainFu.tld_sizes = {:development => 1,
:test => 0,
:production => 1}
在我的初始化程序/subdomain-fu.rb 中
【问题讨论】:
标签: ruby-on-rails subdomain-fu
subdomain-fu gem 中的 tld_size 是什么意思。例如聋哑人,
SubdomainFu.tld_sizes = {:development => 1,
:test => 0,
:production => 1}
在我的初始化程序/subdomain-fu.rb 中
【问题讨论】:
标签: ruby-on-rails subdomain-fu
我已经调试并找到了答案,
如果配置如下表示,
SubdomainFu.tld_sizes = {:development => 1,
:test => 0,
:production => 1}
如果你的 URL 是 test.lvh.me:3000 意味着 subdomain-fu gem 的 current_subdomain 将返回 test。 如果你设置 tld_size 如下,
SubdomainFu.tld_sizes = {:development => 1,
:test => 0,
:production => 0}
那么你的 URL 是 test.lvh.me:3000 意味着 subdomain-fu gem 的 current_subdomain 将返回 test.lvh
谢谢...
【讨论】: