I find that  

print "Content-type: text/html\n\n"; 

doesnt always work.  So I just use 

print $CGI->header;

Regards,
Agustin Rivera
Webmaster, Pollstar.com / Pollstaronline.com

----- Original Message ----- 
From: "Joe Echavarria" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, April 01, 2002 8:15 AM
Subject: no output from the script


> Hi there,
> 
>   When i try to execute the script using the web
> browser i get no output from it but at shell prompt it
> works.
> 
> Here is the script :
> 
> #!/usr/bin/perl -w
> use CGI qw/:all/;
> print "Content-type: text/html\n\n";
> print "<title>- LISTA DE LINKS -</title>";
> open(LISTA,"links") or die "Error ---- > : $!\n";
> open(CATEGORIAS,"categorias") or die "Error ---- > :
> $!\n";
> print "<B>Lista de Categorias </B><BR><BR>";
> print "<form name=\"miforma\" method=\"post\"
> action=\"./links1.cgi\" >";
> print "<select name=\"categorias\" size=\"1\">";
> while ($file1 = <CATEGORIAS>) {
>    ($no,$desc)=split(":",$file1);
>    print "<option value=\"$no\">$no</option>";
> }
> close(CATEGORIAS);
> print "</select><Input type=\"submit\" value=\"GO\">";
> print "<table border=5 cellpadding=5><caption><B>LISTA
> DE LINKS
> </B></caption><tr><th>TEMA</th><th>LINK</th></tr>";
> if (param('categorias'))
>   {
>      $cate= param('categorias');
>      while ($file = <LISTA>) {
>              ($categoria,$link) = split(":",$file);
>              if ($categoria eq $cate) {
>                print "<tr><td>
> $categoria</td><td>$link</td></tr>";
>  }
> }
> }
> print "</table></form>";
> 
> 
> 
> __________________________________________________
> Do You Yahoo!?
> Yahoo! Greetings - send holiday greetings for Easter, Passover
> http://greetings.yahoo.com/
> 
> -- 
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]


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

Reply via email to