Re: helper for root paths

Shai Rosenfeld
2007-12-25T17:01:03Z

Josh Kieschnick wrote:
> i''m not sure what to do when my production environment is not in
the
> root path of the domain when it comes to including things like flash
> files.
>
> when testing, everything works great, but since i don''t have a
helper
> like image_tag, i have to change the url of the flash file each time i
> test and then change it back when i deploy the changes.
>
> is there a helper in rails that will just add the root prefix to urls
> based on the environment?

you can play around w the different environment files (
environments/development.rb | production.rb | test.rb ) and play around
with either

self.document_root = "/some/path"
or the
RAILS_ROOT constant (also, a "some/path/" string)

nothing here is tested, but i hope this leads to some new info or helps
out digging a little further

good luck!
shai
--
Posted via http://www.ruby-forum.com/.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Ruby on Rails: Talk" group.
To post to this group, send email to
rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org