Thursday 4 July 2013

Test perl script

Posted by Sarath On Thursday, July 04, 2013 No comments
To check if perl is working on a server: Open a test file,
# vi test.pl
And enter the following code :

#!/usr/bin/perl
print "Content-Type: text/html\n\n";
print "<html><body><h1>Perl is working!</h1></body></html>";

Save and browse the file, www.yoursite.com/test.pl (replace yoursite.com with your website name).

0 comments: