Changeset 283
- Timestamp:
- 08/10/07 21:34:00 (3 years ago)
- Location:
- veekun/trunk
- Files:
-
- 3 modified
-
lib/Vee/Utils.pm (modified) (2 diffs)
-
lib/Vee/View/TT.pm (modified) (1 diff)
-
templates/shoutbox.tt (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
veekun/trunk/lib/Vee/Utils.pm
r266 r283 3 3 use Socket qw//; 4 4 use List::Util qw/first/; 5 use Digest::SHA1 qw/sha1_hex/; 5 6 6 7 =head1 NAME … … 125 126 sub inet_aton { unpack 'N*', Socket::inet_aton(shift) } 126 127 128 # name comes from what imageboards do, but really it's just a short hash 129 sub tripcode { substr sha1_hex(shift), 0, 12 } 130 127 131 =head1 AUTHOR 128 132 -
veekun/trunk/lib/Vee/View/TT.pm
r202 r283 32 32 hsv2rgb => \&Vee::Utils::hsv2rgb, 33 33 wordcap => \&Vee::Utils::wordcap, 34 tripcode => \&Vee::Utils::tripcode, 34 35 35 36 # forum stuff... -
veekun/trunk/templates/shoutbox.tt
r167 r283 14 14 <tr class="heading"> 15 15 <th class="time">Date/Time</th> 16 [% IF can_ip %]17 16 <th class="ip">IP</th> 18 [% END %]19 17 <th class="user">User</th> 20 18 <th class="message">Shout</th> … … 27 25 <tr class="color[% color %]"> 28 26 <td class="time" title="[% time - s.time | timespan %] ago">[% s.time | date %]</td> 29 [% IF can_ip %] 30 <td class="ip">[% inet_ntoa(s.ip) %]</td> 31 [% END %] 27 <td class="ip">[% can_ip ? inet_ntoa(s.ip) : tripcode(s.ip) %]</td> 32 28 <td class="user"> 33 29 [% IF s.userid %]
