Beefy Boxes and Bandwidth Generously Provided by pair Networks
"be consistent"
 
PerlMonks  

Re: Conditional statements in CGI/Div

by Khen1950fx (Canon)
on Jan 13, 2013 at 21:17 UTC ( #1013129=note: print w/ replies, xml ) Need Help??


in reply to Conditional statements in CGI/Div

I condensed golux's script by 4 lines. Hopefully, this might be a little bit easier to read.

#!/usr/bin/perl -l use strict; use warnings; use CGI qw/:standard/; my $index = 0; if($index == 0) { my $cgi = new CGI; print $cgi->header(), $cgi->start_html(), $cgi->div({-id => 'pagewrap'}, "Hello"), $cgi->end_html(); }
Update: Condensed even more:
#!/usr/bin/perl -l use strict; use warnings; use CGI qw/:standard/; my $index = 0; if($index == 0) { my $cgi = CGI->new; print header, start_html, div({-id=>'pagewrap'}, "Hello"), end_html; }


Comment on Re: Conditional statements in CGI/Div
Select or Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others chilling in the Monastery: (16)
As of 2014-08-27 19:11 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The best computer themed movie is:











    Results (250 votes), past polls