How do I set default host for url helpers in rails?

Posted by ja.kub.cz on Stack Overflow See other posts from Stack Overflow or by ja.kub.cz
Published on 2010-04-17T21:37:13Z Indexed on 2010/04/17 21:43 UTC
Read the original article Hit count: 376

Filed under:
|
|

I would like to do something like this

config.default_host = 'www.subdomain.example.com'

in some of my configuration files, so that object_url helpers produce link beginning with http://www.subdomain.example.com

I have tried to search the docs but I did not find anytnig exept ActionMailer docs and http://api.rubyonrails.org/classes/Rails/Configuration.html which is not usefull for me, because I do not know in which pat to look. Is there a place which describes the whole structure of Rails::Initializer.config?

Thanks for helping Jakub

© Stack Overflow or respective owner

Related posts about ruby-on-rails

Related posts about configuration