> The title variable is to change the title when the page is refreshed.

I believe you are a little lost about how the whole thing works. At
first you said you wanted to change the contents of 'datos' but now
you say you want to change the contents of the tag <title>. I'll
assume from now on it is the later.

  <head>
    <title><%= title %></title>
  </head>

I think there is a typo in your code. Shouldn't it be <%= @title %>?.
Besides that, I have never tried to replace the contents of an element
in the <header> section so I'm not sure it will work. I'd appreciate
if you let me know when you get your code working.

For your code to work you would have to give an id to the element you
want to replace, as in:

<title id="title"><%= @title %></title>

Then it might be a good idea to create a partial and render it to
replace the contents of the tag <title>, although returning just a
string might be OK. You would also need to tell your 'link_to' helper
which HTML element to replace ('title' in this case) and as I
explained before I couldn't see how to do that by looking at the API
with Rails 3. Somebody else already using Rails 3 might be able to
help better than me there.

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to rubyonrails-t...@googlegroups.com.
To unsubscribe from this group, send email to 
rubyonrails-talk+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en.

Reply via email to