Topic: undefined method `link_to_remote'

I am trying to render a partial when someone clicks on a link to enter some information. Most of the blogs/examples use the link_to_remote method to perform this. However I get a NoMethodError error:

undefined method `link_to_remote' for #<Class>

Does anyone know why?
I am using Rails3.

Re: undefined method `link_to_remote'

Did you add     <%= javascript_include_tag :defaults%> in your layout file to activate a prototype helper ?

Re: undefined method `link_to_remote'

Yes I did have that in my layout.

Let me give more background as to what I am trying to achieve:

I have a list of shares, positions, prices, and exposure in a table. I also have a "propose trade" column and next to that a link_to which loads a web page that allows the user to input a proposed buy/sell. When the user clicks "ok" the list of shares reloads and shows the effect for the proposed trade on the portfolio.

What I want to do is make this a bit more elegant. I want to convert the "propose trade" into a partial and when the user clicks on the link_to the partial appears on the top right of the web page above the share list table.

Alternatively, the "propose trade" can be pop-up, and then close when the user clicks OK - but I really dont want to go this route.


Re: undefined method `link_to_remote'

Rails 3 has no longer "link_to_remote". instead use:

link_to "Clique here", url, :remote => true

Re: undefined method `link_to_remote'

link_to "Clique here", url, :remote => true   is used quite long ago. at first i couldn't understand what the matter either)