Hi,

I am trying to use ajax to update a page by using the link_to command.
When I click the link_to commad my ajax request is not being process.

The view is a list of message. Once I click on a message link_to
command, I want it to update the message <div>.
When I click on the link_to command, I get this respond in the url:
http://localhost:3000/mailbox?url[action]=update&remote=true

My javascript is not being render.

Please help. Thanks.

<h2><%=h @folder.name %></h2>
<table border="1">
  <tr>
    <th>From</th>
    <th>Subject</th>
    <th>Received</th>
  </tr>

  <% for message in @messages %>
    <tr>
      <td><%= message.author.login %></td>
      <td><%= link_to
message.subject, :url=>{:action=> :update} , :remote => true %></
td>
      <td><%= distance_of_time_in_words(message.created_at, Time.now)
%> ago</td>
     </tr>
  <% end %>
</table>

<div id="message">

</div>


<%= will_paginate @messages %>

-- 
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 [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en.

Reply via email to