title: What is the replacement for ActionController::Base.relative_url_root?
body: <p>I am porting a 2.x rails app to rails3; we'll call it foo-app. Foo-app is one section of a larger rails app and lives at main_rails_app.com/foo-app. Previously we just set up the following in our foo-app production config to ensure that our foo-app routes worked properly:</p>
  
  <pre><code>ActionController::Base.relative_url_root = "/foo-app"
  </code></pre>
  
  <p>However, with rails3, I now get:</p>
  
  <pre><code>DEPRECATION WARNING: ActionController::Base.relative_url_root is ineffective. Please stop using it.
  </code></pre>
  
  <p>I have since changed the config entry to the following:</p>
  
  <pre><code>config.action_controller.relative_url_root = "/foo-app"
  </code></pre>
  
  <p>This mostly works in that all calls to external resources (javascript/css/images) will use /foo-app. However, none of my routes change appropriately, or put another way, foo-app root_path gives me '/' when I would expect '/foo-app'.</p>
  
  <p>Two questions:</p>
  
  <ol>
  <li>What is the replacement for ActionController::Base.relative_url_root</li>
  <li>if it is config.action_controller.relative_url_root, then why are my routes not reflecting the relative_url_root value I set?</li>
  </ol>