in reply to Problem with cgi script

The first thing is to check in your web server error log. The webserver tells you what happens.

Also, you're not printing the HTML elements. Start with an even simpler script:

use strict; use CGI; my $cgi = CGI->new; print $cgi->header; print '<html><body>Hello World</body></html>';

Then, modify that script to print out the HTML generated by CGI:

... print $cgi->header(); print $cgi->start_html(); print $cgi->p("Hello World"); print $cgi->end_html();

Replies are listed 'Best First'.
Re^2: Problem with cgi script
by nagalenoj (Friar) on Feb 14, 2009 at 11:06 UTC
    That simple script is also not working in the browser.
      Well - what does the webserver error log say? Knowing the error message is the first step in solving the problem.