Implemented fortune

This commit is contained in:
swaggboi 2021-02-27 01:14:38 -05:00
parent 13b91c8ad3
commit eb74988c1e
3 changed files with 5 additions and 16 deletions

View File

@ -3,7 +3,6 @@ body {
background: #000; background: #000;
margin: 8px; margin: 8px;
color: #00FF00; color: #00FF00;
font: normal 16px/20px Courier, Courier New, monospace;
} }
a { a {

View File

@ -108,7 +108,7 @@
+--------------------------+<br> +--------------------------+<br>
</div> </div>
<div class="inner"> <div class="inner">
<!--#include virtual="/cgi-bin/fort.cgi" --> <code><pre><%= $fortune %></pre></code>
</div> </div>
<div class="outer"> <div class="outer">
+--------------------------+<br> +--------------------------+<br>
@ -121,19 +121,8 @@
<div class="outer"> <div class="outer">
+--------------------------+<br> +--------------------------+<br>
</div> </div>
<div class="inner" id="guest">
<p>Please sign the guestbook and let SwaggNet know what you <em>really</em>
think.</p>
<a href="/cgi-bin/guest.cgi">
<img alt="Sign the Guestbook!" src="/Pictures/guest.gif">
</a>
</div>
<br>
<div class="outer">
+--------------------------+<br>
</div>
<div class="inner"> <div class="inner">
<!--#include virtual="/cgi-bin/count.cgi" --> <p>TODO: visitor count goes here</p>
</div> </div>
<div class="outer"> <div class="outer">
+--------------------------+<br> +--------------------------+<br>

View File

@ -4,8 +4,9 @@ use Mojolicious::Lite;
get '/' => sub { get '/' => sub {
my ($c) = @_; my ($c) = @_;
my $fortune = `fortune`;
$c->render() $c->render(fortune => $fortune)
} => 'index'; } => 'index';
app->start(); app->start();