Site icon NgDeveloper

Perl Hello world CGI in xampp server

Download Xampp from

http://www.apachefriends.org/en/xampp-windows.html

Step 1: Create a file named javadomain.cgi and paste the below code,

#!"C:\xampp\perl\bin\perl.exe"
print "Content-type: text/html\n\n";
print "<H1>Hello World</H1>\n";

#!”C:\xampp\perl\bin\perl.exe” is the location of perl.exe.

Step 2: Save this file in C:\xampp\htdocs

Step 3: Open the xampp control panel. which is in c:\xampp.

Step 4: Start the servers,

 

Step 5: Check whether the server is on and working fine by typing localhost in the browsers,

if you didn’t get the above window, then once again open the xampp control panel and restart the server and try again.

Step 6: Type localhost/javadomain.cgi in the browser to get the perl cgi output.

 

Thanks for reading this post…………!!!

Exit mobile version