From 869aff4e43d1c849d3757591aacdc3746c06edb3 Mon Sep 17 00:00:00 2001 From: Yorhel Date: Mon, 7 Sep 2009 09:34:20 +0200 Subject: Handler::Misc: Made box titles on the homepage click-able --- ChangeLog | 2 ++ data/lang.txt | 4 ---- data/style.css | 3 +++ lib/VNDB/Handler/Misc.pm | 22 ++++++++++++++++------ 4 files changed, 21 insertions(+), 10 deletions(-) diff --git a/ChangeLog b/ChangeLog index fd5e7bfd..009d00a8 100644 --- a/ChangeLog +++ b/ChangeLog @@ -10,6 +10,8 @@ git - ? - Merged: alternative setting into alternative version, and other into same series - Allow empty VN descriptions - New platforms: DOS, PC-98, Sega Saturn + - Box titles on homepage are click-able + - Russian translation of the interface 2.6 - 2009-08-09 - New screen resolutions: 1024x600 and 1600x1200 diff --git a/data/lang.txt b/data/lang.txt index b11c60d8..d6c52860 100644 --- a/data/lang.txt +++ b/data/lang.txt @@ -900,10 +900,6 @@ ru : [_1]:[_2], [userstr,_3] en : Announcements ru : Объявления -:_home_newsarchive -en : News Archive -ru : Архив новостей - :_home_recentposts en : Recent Posts ru : Недавние сообщения diff --git a/data/style.css b/data/style.css index c40e35f5..99a46b77 100644 --- a/data/style.css +++ b/data/style.css @@ -401,6 +401,9 @@ p.screenshots { p.screenshots img { margin: 2px; } +#maincontent .mainbox.threelayout h1 a { + color: $boxtitle$; +} diff --git a/lib/VNDB/Handler/Misc.pm b/lib/VNDB/Handler/Misc.pm index 187f1b0c..48ede5c0 100644 --- a/lib/VNDB/Handler/Misc.pm +++ b/lib/VNDB/Handler/Misc.pm @@ -6,6 +6,7 @@ use strict; use warnings; use YAWF ':html', ':xml', 'xml_escape'; use VNDB::Func; +use POSIX 'strftime'; YAWF::register( @@ -59,7 +60,9 @@ sub homepage { # Recent changes td; - h1 mt '_home_recentchanges'; + h1; + a href => '/hist', mt '_home_recentchanges'; + end; my $changes = $self->dbRevisionGet(what => 'item user', results => 10, auto => 1, hidden => 1); ul; for (@$changes) { @@ -77,8 +80,9 @@ sub homepage { # Announcements td; my $an = $self->dbThreadGet(type => 'an', order => 't.id DESC', results => 2); - a class => 'right', href => '/t/an', mt '_home_newsarchive'; - h1 mt '_home_announcements'; + h1; + a href => '/t/an', mt '_home_announcements'; + end; for (@$an) { my $post = $self->dbPostGet(tid => $_->{id}, num => 1)->[0]; h2; @@ -92,7 +96,9 @@ sub homepage { # Recent posts td; - h1 mt '_home_recentposts'; + h1; + a href => '/t', mt '_home_recentposts'; + end; my $posts = $self->dbThreadGet(what => 'lastpost boardtitles', results => 10, order => 'tpl.date DESC', notusers => 1); ul; for (@$posts) { @@ -125,7 +131,9 @@ sub homepage { # Upcoming releases td; - h1 mt '_home_upcoming'; + h1; + a href => strftime('/r?mi=%Y%m%d;o=a;s=released', gmtime), mt '_home_upcoming'; + end; my $upcoming = $self->dbReleaseGet(results => 10, unreleased => 1, what => 'platforms'); ul; for (@$upcoming) { @@ -142,7 +150,9 @@ sub homepage { # Just released td; - h1 mt '_home_justreleased'; + h1; + a href => strftime('/r?ma=%Y%m%d;o=d;s=released', gmtime), mt '_home_justreleased'; + end; my $justrel = $self->dbReleaseGet(results => 10, order => 'rr.released DESC', unreleased => 0, what => 'platforms'); ul; for (@$justrel) { -- cgit v1.2.3