Junior Member from PE
joined:Mar 28, 2004
I am using WAMP to practice with CGI and Perl.
My problem is when I execute the cgi script, Firefox shows it as HTML source code, but I am not in page source view. Below is the code I am using:
This is what Firefox shows:
#use CGI::Carp 'fatalsToBrowser';
#use CGI qw(-debug);
print "Content-type: text/plain\n\n";
print "<html><head><title>Hello World</title></head>\n";
print "<h2>Hello, world!</h2>\n";
I searched on Google, and found that I should add "AddType text/html .html .htm", but that did not help either.
Any idea why this could be happening?