diff --git a/lib/PostText.pm b/lib/PostText.pm index f8e2ca9..4afb10f 100644 --- a/lib/PostText.pm +++ b/lib/PostText.pm @@ -135,6 +135,8 @@ sub startup($self) { $r->get('/rules')->to('page#rules')->name('rules_page'); + $r->get('/feeds')->to('page#feeds')->name('feeds_page'); + $r->any([qw{GET POST}], '/captcha/*return_url') ->to('page#captcha') ->name('captcha_page'); diff --git a/lib/PostText/Controller/Page.pm b/lib/PostText/Controller/Page.pm index d08cf7b..e8614bc 100644 --- a/lib/PostText/Controller/Page.pm +++ b/lib/PostText/Controller/Page.pm @@ -8,6 +8,8 @@ sub about($self) { $self->render } sub rules($self) { $self->render } +sub feeds($self) { $self->render } + sub captcha($self) { my $v; diff --git a/t/page.t b/t/page.t index 910fc49..1a8ac87 100644 --- a/t/page.t +++ b/t/page.t @@ -8,4 +8,6 @@ $t->get_ok('/about')->status_is(200)->text_like(h2 => qr/About Post::Text/); $t->get_ok('/rules')->status_is(200)->text_like(h2 => qr/The Rules/); +$t->get_ok('/feeds')->status_is(200)->text_like(h2 => qr/Feeds/); + done_testing; diff --git a/templates/layouts/default.html.ep b/templates/layouts/default.html.ep index 6ae8491..0da6d6c 100644 --- a/templates/layouts/default.html.ep +++ b/templates/layouts/default.html.ep @@ -40,11 +40,7 @@ <%= link_to New => post_thread => (class => 'click') %> <%= link_to About => about_page => (class => 'click') %> <%= link_to Rules => rules_page => (class => 'click') %> - <%= link_to RSS => threads_feed => {format => 'rss'}, - (class => 'click') %> - <% if (is_mod) { =%> - <%= link_to Logout => mod_logout => (class => 'click') %> - <% } =%> + <%= link_to Feeds => feeds_page => (class => 'click') %> <% if (is_mod) { =%> <% } =%> <% if (is_admin) { =%> diff --git a/templates/page/feeds.html.ep b/templates/page/feeds.html.ep new file mode 100644 index 0000000..88abf79 --- /dev/null +++ b/templates/page/feeds.html.ep @@ -0,0 +1,28 @@ +% layout 'default'; +% title 'Feeds'; +% content_for open_graph => begin + + + +% end +% content_for twitter_card => begin + + +% end +

<%= title %>

+
+

You can stay up-to-date with the latest mindless drivel by + subscribing to these feeds using the feed + reader of your choice!

+ +