Create dynamic search with table rows

I’m trying to create a dynamic search function to filter the list
results using form_remote_tag. I need this to work with a table data
output. So it would update the partial template of table rows. I
tried wrapping the table rows in a div tag but that wouldn’t update
the table properly. Any help on this would be greatly appreciated.

Here is my code:

<%= form_remote_tag :update => “student_list”, :url => { :action =>
“list” } %>

<%= submit_tag “Search” %>

<%= render :partial => "student_list", :collection => @students %>
Name Grade School  

Try using thead and tbody…

<%= render :partial => "student_list", :collection => @students %>
Name Grade School  


That worked great, thanks.

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs