From 5f44411d948f0cefb6a968a357d305c4c97c2174 Mon Sep 17 00:00:00 2001 From: Sam Stephenson Date: Mon, 23 Jan 2006 07:27:24 +0000 Subject: Backing out of [3470] until visual_effect, et al can work git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3471 5ecf4fe2-1ee6-0310-87b1-e25e094e27de --- actionpack/CHANGELOG | 14 ------ actionpack/lib/action_controller/base.rb | 5 +- .../lib/action_view/helpers/prototype_helper.rb | 58 ++++++---------------- 3 files changed, 16 insertions(+), 61 deletions(-) diff --git a/actionpack/CHANGELOG b/actionpack/CHANGELOG index 7476c736ac..bf00979083 100644 --- a/actionpack/CHANGELOG +++ b/actionpack/CHANGELOG @@ -1,19 +1,5 @@ *SVN* -* Add the ability to call JavaScriptGenerator methods from helpers called in update blocks. [Sam Stephenson] Example: - module ApplicationHelper - def update_time - page.replace_html 'time', Time.now.to_s(:db) - page.visual_effect :highlight, 'time' - end - end - - class UserController < ApplicationController - def poll - render :update { |page| page.update_time } - end - end - * Fixed that SSL would not correctly be detected when running lighttpd/fcgi behind lighttpd w/mod_proxy #3548 [stephen_purcell@yahoo.com] * Added the possibility to specify atomatic expiration for the memcachd session container #3571 [Stefan Kaes] diff --git a/actionpack/lib/action_controller/base.rb b/actionpack/lib/action_controller/base.rb index 7f8ff5ed09..0a9368f684 100755 --- a/actionpack/lib/action_controller/base.rb +++ b/actionpack/lib/action_controller/base.rb @@ -687,7 +687,7 @@ module ActionController #:nodoc: end def render_javascript(javascript, status = nil) - @response.headers['Content-Type'] = 'text/javascript' + @response.headers['Content-type'] = 'text/javascript' render_text(javascript, status) end @@ -719,8 +719,7 @@ module ActionController #:nodoc: @response.body = nil @performed_render = false end - - + # Clears the redirected results from the headers, resets the status to 200 and returns # the URL that was used to redirect or nil if there was no redirected URL # Note that +redirect_to+ will change the body of the response to indicate a redirection. diff --git a/actionpack/lib/action_view/helpers/prototype_helper.rb b/actionpack/lib/action_view/helpers/prototype_helper.rb index edf6f50a06..d35334a98c 100644 --- a/actionpack/lib/action_view/helpers/prototype_helper.rb +++ b/actionpack/lib/action_view/helpers/prototype_helper.rb @@ -370,52 +370,34 @@ module ActionView # this in your Ajax response bodies, either in a