Re: Problems with link_to_remote

user splash
2008-01-24T03:50:16Z

Ryan Bigg wrote:
> You cannot put a div inside a table row. It is not working because
> you''ve
> used the class attribute on the div.
>
> Change class to id and get rid of the div, and set the id attribute on
> the
> tr tag.
>
>
> --
> Ryan Bigg
> http://www.frozenplague.net
> Feel free to add me to MSN and/or GTalk as this email.


Hi,

oh...After changing the class to id it I manage to display some text. As
I use this codes in the controller to test out the link.

def add_item
render_text " Item " + DateTime.now.to_s +
" "
end


But there are still some problems and questions I want to ask. Even
though in the link_to_remote, I set the text to be displayed after the
original label and text field by using :position => "bottom", the
text
is being displayed on top of the original one. Can someone tell me why
or what happened here?

The other question is when I click the link, a new label with the number
incremented, Item 1 and a new text field will appear below the previous
label, Item 0 and text field. How do I achieve that?

Thanks