]> projects.mako.cc - selectricity-live/blobdiff - app/views/quickvote/_pref_table.rhtml
Close tables
[selectricity-live] / app / views / quickvote / _pref_table.rhtml
index 4576a0fafb8e7971af4499ba88b9501bacb1a2aa..a3ba63d7faac2af1dfa85a02c67c3dc26fa78e42 100644 (file)
@@ -9,17 +9,19 @@
   <tr>
        <td> </td>
        <% candidates.each do |candidate| -%>
-         <th><%= names[candidate] -%></th>
-       <% end -%>
+         <th><%=h names[candidate] -%></th>
+  <% end -%>
+</tr>
+
 <% candidates.each do |winner| -%>
   <tr>
-       <th><%= names[winner] %></th>
+       <th><%=h names[winner] %></th>
   <% candidates.each do |loser| -%> 
     <% if winner == loser -%>
       <td> -- </td>
     <% else %>         
       <td><% wins = @election.condorcet_result.matrix[winner][loser]%>
-          <%= wins %>
+          <%=h wins %>
              <%= sparkline_tag [(wins.to_f/voters.to_f)*100.0], :type => 'pie', 
                                 :diameter => 25, :share_color => '#74ce00' %>
          </td>
@@ -27,4 +29,4 @@
   <% end -%>
  </tr>
 <% end -%>
-
+</table>

Benjamin Mako Hill || Want to submit a patch?