diff options
author | David Heinemeier Hansson <david@loudthinking.com> | 2005-04-17 14:10:24 +0000 |
---|---|---|
committer | David Heinemeier Hansson <david@loudthinking.com> | 2005-04-17 14:10:24 +0000 |
commit | 7cda49248b5269b1aaf96729a31f85a315fbb764 (patch) | |
tree | 629a18744e19eb0e7d1e424d2588782702e871d9 /actionpack/lib/action_controller/caching.rb | |
parent | 7ff635c8eb84253da909c55c0b01ae38fe17d4a0 (diff) | |
download | rails-7cda49248b5269b1aaf96729a31f85a315fbb764.tar.gz rails-7cda49248b5269b1aaf96729a31f85a315fbb764.tar.bz2 rails-7cda49248b5269b1aaf96729a31f85a315fbb764.zip |
Fixed page caching for non-vhost applications living underneath the root #1004 [Ben Schumacher]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1193 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'actionpack/lib/action_controller/caching.rb')
-rw-r--r-- | actionpack/lib/action_controller/caching.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/actionpack/lib/action_controller/caching.rb b/actionpack/lib/action_controller/caching.rb index 159a1ba14e..5b5cdaa2e3 100644 --- a/actionpack/lib/action_controller/caching.rb +++ b/actionpack/lib/action_controller/caching.rb @@ -114,10 +114,10 @@ module ActionController #:nodoc: return unless perform_caching if options[:action].is_a?(Array) options[:action].dup.each do |action| - self.class.expire_page(url_for(options.merge({ :only_path => true, :action => action }))) + self.class.expire_page(url_for(options.merge({ :only_path => true, :skip_relative_url_root => true, :action => action }))) end else - self.class.expire_page(url_for(options.merge({ :only_path => true }))) + self.class.expire_page(url_for(options.merge({ :only_path => true, :skip_relative_url_root => true }))) end end @@ -126,7 +126,7 @@ module ActionController #:nodoc: # cache_page "I'm the cached content", :controller => "lists", :action => "show" def cache_page(content = nil, options = {}) return unless perform_caching && caching_allowed - self.class.cache_page(content || @response.body, url_for(options.merge({ :only_path => true }))) + self.class.cache_page(content || @response.body, url_for(options.merge({ :only_path => true, :skip_relative_url_root => true }))) end private |