> > That's normal: rake tasks are outside the request cycle, so they've no > way of knowing how people access the site (ie localhost, a dotted ip > address, one of the many domain names pointing at the server). > Maybe you could explain what it is you are trying to do? > > Fred I'm trying to send out an email from within the rake task, and I need to include a link in the email to a certain page on my site.
In development, I'd want the page to be "http://localhost:3000/fruits/my_fruit", but in production, I'd want it to be "http://apples.com/fruits/my_fruit" I'd rather not hard-code in the domain names, I'd like some way to just grab what domain I'm on and use that. -- 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 [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---

