Well,
If your using CGI.pm you have the power and flexibility of using the object parameters 
like "q->" it's really a great short hand for coding pages esspecially for headers and 
footes and tables and style sheets and the like. Of course you can blend CGI.pm 
formatted code with HTML here documents like the one in your example.

You could use:
print $q->header( -type => "text/html", -expires => "now" ),
      $q->start_html( -title => "Your Title",
-bgcolor=> "#FFFFFF", -text=> "#000000", -style=>{'src'=>'/style1.css'},
-script=>{-language=>'JavaScript', -src=>'/rollover.js'});

then your here doc:

print qq`
<table width="100%" border="0" cellpadding="0" cellspacing="0">
 <tr bgcolor="#cccccc">
  <td>&nbsp;</td>
 </tr>
</table>`;

$q->end_html;

I do it all kinds of ways. Depends on what your trying to write. For nestled tables 
though, I'd say the latter is easier. GL, Mark

-----Original Message-----
From: "Octavian Rasnita"<[EMAIL PROTECTED]>
To: [EMAIL PROTECTED]
Date: Sun Mar 17 03:11:19 PST 2002
Subject: Using CGI.pm

>Hi all,
>
>I have   a question about using CGI.pm.
>
>How it is better? To print directly the html code with 
>print "<html> <head> <title> ...</title> </head>"; etc.  or
>
>to print using the CGI.pm
>print $q-> start_html(...); etc.
>Does it work faster in a way or another, or are there any advantages?
>I saw that some things can't be made using CGI.pm.
>
>Thanks.
>Teddy,
>My dear email address is [EMAIL PROTECTED]
>
>
>
>
>_________________________________________________________
>
>Do You Yahoo!?
>
>Get your free @yahoo.com address at http://mail.yahoo.com
>
>
>
>
>-- 
>To unsubscribe, e-mail: [EMAIL PROTECTED]
>For additional commands, e-mail: [EMAIL PROTECTED]
>


___________________________________________________
GO.com Mail                                    
Get Your Free, Private E-mail at http://mail.go.com



-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to