views:

49

answers:

2

I'm new to Ruby on Rails and am creating a test application. So far, it's working, but when I make some minor changes to my views, the page doesn't change.

My problem may be related to this question, but I'm not sure what is meant by setting the date and time in the VM. My code is on a remotely hosted server, so I assume it would use the system time of that machine.

Is there a caching issue here? What can I do about it?

+2  A: 

You need to restart your Rails app (or Apache if you are using Passenger) if you are in production mode!

Lennart
+3  A: 

If you don't have control over the server environment yourself (no shell access, etc.), you can set the following at the top of config/environment.rb:

ENV['RAILS_ENV'] = 'development'

Development doesn't cache much, so while it's slower it's much nicer to develop in.

You'll still need to restart your app after making changes to anything outside the app/ folder though (configs, plugins, etc.).

Luke
I did this, but changes still don't show until I restart Mongrel. (I do have SSH access.)
Nathan Long
Am I missing something else?
Nathan Long
Try getting your templates to echo `Rails.env`, to see if it's actually being picked up by Rails.What version of Rails are you running? (Echo `Rails.version` in your template)
Luke