Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask
 
PerlMonks  

Ugly code! :-(

by orkysoft (Friar)
on Mar 02, 2001 at 09:51 UTC ( #61746=note: print w/ replies, xml ) Need Help??


in reply to Re: Re: Perl & Personal Web Server
in thread Perl & Personal Web Server

I'd do it like this:

#!/usr/bin/perl -w use CGI; my $q = new CGI; print $q->header, $q->start_html, $q->start_table; # etc
Okay, so actually this requires more finger acrobatics, but at least it looks a lot better to me. But then, 'an old version of Perl' might very well mean Perl 4, which doesn't have OO. (But that's before my time, I believe I've just missed my first Perl anniversary ;-)


Comment on Ugly code! :-(
Download Code
Replies are listed 'Best First'.
Re: Ugly code! :-(
by Anonymous Monk on Mar 02, 2001 at 10:46 UTC

    Of course it looks much better that way, orkysoft. Not to take any points away from beauty, the point was be 'verbose' in reminding beginners to 'use CGI'.

    A bit of (I'd hoped) useful (but dubitable) humor, you see. :-)
    mkmcconn

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://61746]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others chilling in the Monastery: (12)
As of 2015-07-28 22:16 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (260 votes), past polls