Nik has asked for the wisdom of the Perl Monks concerning the following question:
if( param('Εμφάνιση Guestbook!') ) { $sth = $dbh->prepare( 'SELECT * FROM guestbook' ); $sth->execute; while( $row = $sth->fetchrow_hashref ) { print table( {class=>'user_form'}, Tr( td( {-width=>'25%'}, {class=>'name'}, $row->{ +name} ), td( {-width=>'50%'}, {class=>'email'}, $row->{ +email} ), td( {-width=>'25%'}, {class=>'date'}, $row->{ +date} ) ), Tr( td( {class=>'host'}, "Ευχή τ +ου Ιησού" ), td( {colspan=>2}, {class=>'tip'}, $row->{ +pray} ) ), Tr( td( {class=>'tip'}, "Προσωπ +ική Ορθοδοξοπνευματική Εμπειρία" ), td( {colspan=>2}, {class=>'remark'}, $row->{ +remark} ) ), Tr( td( {colspan=>3}, {class=>'host'}, $row->{ +host} ) ), ), br() x 2; } unless ($sth->rows ) { print span( {class=>'tip'}, "Δεν υπάρχουν νέες εγγραφές, yet!" + ); } }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Perl and a little style.
by tlm (Prior) on May 02, 2005 at 13:02 UTC | |
by ghenry (Vicar) on May 02, 2005 at 13:06 UTC | |
| |
|
Re: Perl and a little style.
by wfsp (Abbot) on May 02, 2005 at 14:26 UTC | |
|