% max_total = @hosts.inject(0) {|m,a| a['total'].to_i > m ? a['total'].to_i : m }%>
# | Hits | Hostname | Percentage | |
---|---|---|---|---|
<%= i %> | <%= host.total %> | <%= link_to host.ip, "http://cqcounter.com/whois/?query=#{host.ip}", :target=>'_blank' %> | <%= sprintf("%000.2f",(host.total.to_f/@total_hits)*100) %>% | <%=image_tag 'sitealizer/bar.gif', :width => width, :height => 3%> |