11155
(-- --)
1
Hey,
how can i get an whole <td> cell to be a link.
my actual code is:
<% @alluser.each do |x| %>
<%= link_to "#{x.name}", { :controller => 'pages', :action =>
'berufsschule', :given_user => x.name} , :class => "btn btn-danger" %>
<% end %>
i want a whole table cell as link.. not only the text
thanks
You need to use javascript for that. Try adding the onclick attribute on the td element.
11155
(-- --)
3
and how would it look like?
i don't know how to use all instance variables (e.g. :given_user) with
the onclick!
Please give an example....