Created
August 2, 2011 14:11
-
-
Save groman-me/1120261 to your computer and use it in GitHub Desktop.
get _path from model
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
http://stackoverflow.com/questions/341143/can-rails-routing-helpers-i-e-mymodel-pathmodel-be-used-in-models | |
In Rails 3: | |
Rails.application.routes.url_helpers | |
Rails 2 | |
include ActionController::UrlWriter |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment