projects
/
selectricity-live
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (from parent 1:
df81b74
)
Add ability to parse RIPE WHOIS too
author
John Dong
<jdong@mit.edu>
Thu, 16 Aug 2007 20:33:40 +0000
(16:33 -0400)
committer
John Dong
<jdong@mit.edu>
Thu, 16 Aug 2007 20:33:40 +0000
(16:33 -0400)
app/views/quickvote/results.rhtml
patch
|
blob
|
history
diff --git
a/app/views/quickvote/results.rhtml
b/app/views/quickvote/results.rhtml
index a2b12068830a7cb0d7d4adde770334d0a425d65c..b82d5e3865f4bd2891e2908c6104e407302277f1 100644
(file)
--- a/
app/views/quickvote/results.rhtml
+++ b/
app/views/quickvote/results.rhtml
@@
-160,8
+160,9
@@
by several other names.</p>
<% w= Whois::Whois.new(IPAddr.new(voter.ipaddress).to_s,true)%>
<%=(w.host == nil or w.host.empty?) ? "Unknown voter" : w.host%>
</td>
<% w= Whois::Whois.new(IPAddr.new(voter.ipaddress).to_s,true)%>
<%=(w.host == nil or w.host.empty?) ? "Unknown voter" : w.host%>
</td>
- <td>
- <%= w.search_whois.grep(/^OrgName/)[0].sub(/^OrgName\:/,'').strip %>
+ <td>
+ <%w.search_whois%>
+ <%= (w.all.grep(/^(OrgName|org-name)/)[0] or "").sub(/^(OrgName|org-name)\:/,'').strip -%> - <%= (w.all.grep(/^(NetName|netname)/)[0] or "").sub(/^(NetName|netname)\:/,'').strip %>
<% rescue ArgumentError => err %>
<%= err %>
<% rescue ArgumentError => err %>
<%= err %>
Benjamin Mako Hill
||
Want to submit a patch?