Embarrassing question about rhtml

Apologies for my own ignorance, I am an old UNIX hack that misses the
good old VT100 character display days.

I've modified information in our current/ruby/app/views/_contact.rthml
file to reflect new information but it does not appear when I reload
the browser. I've tried a few other .rhtml files as well -all very
simple content changes.

What am I missing (besides a brain?) Is there some command that has to
be issued (I thought rhtml changes would reflect immediately). Also,
thinking that perhaps I changed an old version of the file, and a
different _contact.rhtml file is active I went to our base directory,
found all versions of _contact.html and changed all of them in attempt
to mitigate the humiliation of this public display of ineptitude.

Thanks in advance for your help,

George

alonovo wrote:

Apologies for my own ignorance, I am an old UNIX hack that misses the
good old VT100 character display days.

I've modified information in our current/ruby/app/views/_contact.rthml
file to reflect new information but it does not appear when I reload
the browser. I've tried a few other .rhtml files as well -all very
simple content changes.

What am I missing (besides a brain?) Is there some command that has to
be issued (I thought rhtml changes would reflect immediately). Also,
thinking that perhaps I changed an old version of the file, and a
different _contact.rhtml file is active I went to our base directory,
found all versions of _contact.html and changed all of them in attempt
to mitigate the humiliation of this public display of ineptitude.

Thanks in advance for your help,

George

Are you doing any caching? The browser may be retrieving the cached version of that page. Check your public/cache directory.

Nope, no public/cache directory. I also did a find . -name 'cache' -
print to see if it was in another spot -and nada.

alonovo wrote:

Nope, no public/cache directory. I also did a find . -name 'cache' -
print to see if it was in another spot -and nada.

Try running the Rails app in development mode. It should be picking up .rhtml changes even in production mode but there may be something else going on that's causing it to not see the changes.

If that doesn't work I'd shut down the Rails app, check the URL with the browser to make sure it really is down and you aren't actually pointing at a different app, clear your browser's cache, start up the Rails app, and try it again.

Thanks Aryk, Thanks Michael -I have a feeling that I've got the wrong
code tree (and not a caching problem). What configuration file (or
hierarchy) would determine the code tree?

-George

Now, this might be a really dumb suggestion as I'm sure this was
working before, but one thing strikes me is that your _contact.rhtml
is a partial and it's sitting in the base of the views directory (app/
views/).

This may be exactly as it should be, but generally, partials are
controller specific (i.e. appear in a controller's sub directory such
as /contacts/_form.rhtml).

Please accept may apologies if this is no help, but I always find
myself over-complicating simple bug fixes so I thought it best to
check :0)

If you're still stuck, it'd be helpful to see the code that you use to
call the partial (e.g. <%= render :partial => "/contact" %>)

Cheers,

Steve

Hi Steve,

It's a good suggestion, however I don't know enough about RoR to
understand the concept of partials. The best real world example is
that the file
../current/ruby/app/views/static/_about.rhtml now has our mailing
address and phone as the last piece of content. Yet when I navigate to
http://www.alonovo.com/about -the information is old and doesn't
reflect the update to the .rhtml page.

There is no ../current/ruby/app/views/about directory either.

I've stopped and started lighttpd (in Michael's suggestion), but no
joy.

Our pages are inconsistent at this point (we use Civicspace Labs/
Drupal for our community interaction and news aggregation -and they
have the most current about us and contact stuff) but the RoR side
doesn't and it is leading to problems.

Any other ideas?

Thanks, George

Hey,

OK - first off, partials are basically a section of view template code
that you normally call via another template. For example, if I had a
preview of a shopping cart that should show on different pages, I
might have a partial called '_preview.rhtml' in /app/views/cart/.
This could be called from other templates using:
<%= render :partial => "cart/preview" %>

As for your specific problem, I assume that you're using some sort of
CMS application if it's not something you've developed yourself. If
this is case, could you let us know the name of the application?

If it's a bespoke application, you may have to do a bit source code
digging. I'd suggest starting in config/routes.rb to find out which
controller and action is handling the 'about' url. From there you
should be able to figure out which view is being called. If not,
perhaps you could post the contents of that action and we'll see if we
can figure it out.

Steve

Thanks Steve,

Still going nuts and appreciate the guidance. The application was
developed by a third party to our specs, they didn't deliver much
documentation and as our quest for funding has been prolonged (and
thus far unsuccessful) I haven't been able to maintain an engineering
staff. I don't expect this group to be either.

Nevertheless, I just feel I'm close, and if I understand which .rhtml
files to change, and how to get them used -then I'll be able to
maintain the site (while continuing to acquire investment in this
work).

Thanks again -

routes.db follows -

ActionController::Routing::Routes.draw do |map|

  map.connect 'browse/:search_index/*browse_node_ids',
              :controller => 'amazon',
              :action => 'browse',
              :defaults => {
                :search_index => nil
              }

  map.connect 'search',
              :controller => 'amazon',
              :action => 'search'

  map.connect 'item/:asin',
              :controller => 'amazon',
              :action => 'item'

  map.connect 'cart',
              :controller => 'amazon',
              :action => 'cart'

  map.connect 'checkout',
              :controller => 'amazon',
              :action => 'checkout'

  map.connect 'item/:asin/colors/:color_name',
              :controller => 'amazon',
              :action => 'colors',
              :defaults => {
                :color_name => nil
              }

  map.connect 'confirm/:token',
              :controller => 'login',
              :action => 'confirm'

  map.connect 'companies/:starts_with',
              :controller => 'sri',
              :action => 'companies',
              :defaults => {
                :starts_with => 'A'
              }

  map.connect 'SRI',
              :controller => 'sri',
              :action => 'companies',

Ok, I figured it out with help from Ethan McCutchen of Grass Commons
and Matt Cowley -all is good in the world. We have a split web/app
server -unfortunately when ssh'ing into one or the other, the session
would open on the wrong machine. By ssh'ing in to the environment, and
then ssh'ing again to the specific machine I was able to directly edit
the rhtml files I needed and voila.

Thanks to all for your patience.

-George