Displaying 20 results from an estimated 1000 matches similar to: "Fragment Cache in ActionMailer"
2008 Jun 09
3
Rails 2.1 and ddatetime_select
I''ve updated to 2.1 and am continuing to have issues with
datetime_select helpers which worked fine previously.
Example:
<% form_remote_tag(:url => { :controller => ''notes'',
:action
=> :add_booking_note_ajax,
:id => @booking},
2006 Nov 05
0
Any workaround for Rails caching?
> > I mean fragment caching. I get errors like this:
> >
> > ActionView::TemplateError
> >
(/usr/lib/ruby/gems/1.8/gems/markaby-0.5/lib/markaby/builder.rb:192:in
> > `method_missing'': no such method `length'') on line
#0
> > of app/views/items/index.mab:
> > 1:
> > 2: cache("#{@site.server_name}/index_items") do
> >
2009 Jun 11
1
fragment caching file_store problems
Hello,
I''m having problems on both my production and development servers with
fragment caching.
Every time I try to cache something using <% cache do %>, I get the
following error:
Couldn''t create cache directory: views/0.0.0.0:3000/jobs/106/questions/
174 (wrong number of arguments (2 for 1))
but strangely, all of the directories apart from the last one are
created.
2007 Sep 07
2
memcached and fragment storage, session storage with a mongrel cluster
Greetings,
I posted this not on the Rails mailing list and didn''t get a definitive
response so I thought I''d post it here, since I figure lots of you
are using
mongrel with Rails apps. Any suggestions would be greatly appreciated.
I''ve been using file-based fragment caching and DB-based session
caching quite extensively. I decided to try out memcached for both to
2007 Jan 11
0
Including partials in ActionMailer template files?
I have class called:
class Notifier < ActionMailer::Base
Then in my view for that class I have an rhtml file that holds the html
for the email. I am trying to do
<%= render :partial => "header" %>
and I''m getting:
ActionView::TemplateError (undefined method `controller_path'' for
Notifier:Class) on line #1 of
2009 Apr 18
0
A bug in sweeper.rb? [was: A frustrating and strange error when config.action_controller.perform_caching = true]
I fired up the debugger and watched the code happen tonight.
The problem occurs if the config.action_controller.perform_caching = true in
your environment. It''s not set to true in development but it is set to true
in production and staging.
The problem occurs not in my controllers but in sweeping.rb (part of rails).
Rails calls this code for every controller which was instantiated in
2007 Oct 27
1
Edge Javascript caching just not working
For some reason, in production, with this one line of code:
javascript_include_tag :all, :cache => true
I get this:
<script cached="true" src="/javascripts/prototype.js?1193454472"
type="text/javascript"></script>
<script cached="true" src="/javascripts/effects.js?1193454472"
type="text/javascript"></script>
2010 Jun 08
1
session_options[:secure] resets session_id on every request
I''m working on an ecommerce site (in Rails 2.3) and I added:
ActionController::Base.session_options[:secure] = true
to ~/config/environments/production.rb
Now, every time I add something to my shopping cart and navigate away I
get a new session_id (which essentially empties my shopping cart).
How can I get the continuity of my sessions back, while still having the
session_id get set
2006 Jan 16
1
Problem with production on Dreamhost - TemplateError
Hi all,
I''m trying to deploy my app to Dreamhost for production. I''ve managed to
solve all of the Error 500s and it''s *almost* working.
When I try and view a page, I get a TemplateError that I don''t get when
I''m running from home using InstantRails under Windows.
The error is:
ActionView::TemplateError (undefined method `user?'' for
2005 Dec 19
8
Single Table Inheritance question
Hello,
I''m having a heck of a time getting Single Table Inheritance to work in my app.
I have the following models and have scaffolded out Person and Contact.
person.rb
class Person < ActiveRecord::Base
has_many :contacts
end
client.rb
class Client < Person
end
contact.rb
class Contact < ActiveRecord::Base
belongs_to :person
end
phone.rb
class Phone < Contact
end
In
2007 Apr 05
5
Odd error handling in ActionView#compile_template causes WSOD
If a view file cannot be compiled (eg it has a block with a missing
''end'' statement), I''m experiencing WSODs - the browser reports a lost
network connection, rather than the helpful compilation error that we
used to have.
When the compilation fails, ActionView#compile_template raises this
error :
TemplateError.new(find_base_path_for(file_name || template), file_name
||
2008 Sep 15
0
Caching RJS fragments
Do you have any hint for using fragment caching within a RJS response?
I''ve the following piece of code in a rjs template
for hotel in @hotels
cache(:id => hotel.id, :format => params[:format]) do
page.insert_html(:bottom, :items, :partial => hotel, :locals =>
{ :city => @city, :country => @country })
end
end
but when the response is rendered it returns the
2007 Aug 30
1
alias_method_chain stack level too deep in Rake test only
I have an odd error. I have the following module:
module ActionController
module SslSupport
def self.included(base)
raise "#{base} does not define url_for" unless
base.method_defined?(:url_for)
unless base.respond_to?(:url_for_without_ssl_supprt)
base.send :include, InstanceMethods
base.send :alias_method_chain, :url_for, :ssl_support
end
2009 Apr 17
0
A frustrating and strange error when config.action_controller.perform_caching = true
Hello all.
I am having a hell of a problem and it''s driving me nuts. I get the
following error (undefined method `controller_name'' for nil:NilClass): but
only when config.action_controller.perform_caching = true
I googled around some and found this thread
http://groups.google.com/group/communityengine/browse_thread/thread/b84154e5228bf9f3which
suggests it may be a conflict with
2006 Aug 01
2
Same <img> is still downloaded for several times in IE
Last time i ask the same question here that if one article item has a
default icon in front of its title,the icon will be downloaded as many
times as the article items displayed in one page in IE. I was suggested
to modify some options under development enviroment,eg:
config.cache_classes and config.action_controller.perform_caching in
development.rb are both set to true.But the problem still
2005 Sep 27
2
caching in development mode
Hi, I created some new models that do not extend
ActiveRecord::Base. For some reason, these classes are being cached
in development mode. Controllers are not cached, neither are models
extending ActiveRecord::Base. Has anyone else seen this?
Here are my relevant development.rb settings:
Dependencies.mechanism = :load
2008 Sep 12
1
Ruby Pages Not Updating
I am a complete beginner to Ruby. I followed the tutorial to create my
own scaffold called Books. My problem is that, when I make changes to
its index.html.erb, the http://url/books page does not update for a
few minutes. I am using a development environment, and the
config.action_controller.perform_caching value is already set to
false. Any help would be appreciated!
2009 Jun 10
1
[PATCH] remove rails2.3 deprecated config.action_view.cache_template_extensions
---
src/config/environments/development.rb | 1 -
1 files changed, 0 insertions(+), 1 deletions(-)
diff --git a/src/config/environments/development.rb b/src/config/environments/development.rb
index b3acf68..9bd4fa6 100644
--- a/src/config/environments/development.rb
+++ b/src/config/environments/development.rb
@@ -33,7 +33,6 @@ config.whiny_nils = true
# Show full error reports and disable
2008 Jul 23
0
Link_to_remote object missing
Hello, I''m in troubles trying to use ''link_to_remote'' on Rails 2.1.
Having this page:
<h4>Editing project</h4>
<% form_for(:project, :url => project_path(@project), :html =>
{ :method => :put }) do |f| %>
<p>
Name <%= f.text_field :name %>
Date <%= calendar_date_select :project, :target_date, :time =>
2008 Mar 13
0
ActionView::TemplateError when FQL query does not return any results
I submitted this as a bug here:
http://rubyforge.org/tracker/index.php?func=detail&aid=18799&group_id=4187&atid=16130
However, I just realized that I probably should have posted here first. Has
anyone else had a similar experiance with queries that don''t return results?
I have the following FQL Query:
"SELECT uid FROM user WHERE has_added_app = 1 AND uid IN (SELECT