refactored the results page
[selectricity-live] / app / views / quickvote / _result.rhtml
index a3264598fb776945ffa4924a478ba7b3fffe59e5..e0ead6de4e3f27b60524554f0b06241578fcd169 100644 (file)
@@ -1,10 +1,10 @@
-<% %>
+<div class="winner">
 <% if result.winner? and result.winners.length == 1%>
-  <p><em>The winner is:
-     <strong><%= @candidates[result.winner].name %></strong></em></p>
+  <p>The winner is:
+     <strong><%=h @candidates[result.winner].name.capitalize %></strong></p>
 <% elsif result.winner? and result.winners.length > 1 %>
-  <p><em>There was a tie. The winners are: <strong><%=
-  result.winners.collect {|w| @candidates[w]}.join(", ") %></strong></em></p>
+  <p>There was a tie. The winners are: <strong><%=h( result.winners.collect {|w| @candidates[w].to_s.capitalize}.join(", ") )%></strong></p>
 <% else %>
-  <p><em>There is no winner using this method. </em></strong></p>
+  <p>There is no winner using this method. </strong></p>
 <% end %>
+</div>

Benjamin Mako Hill || Want to submit a patch?