How to run perl?

Problems with the Windows version of XAMPP, questions, comments, and anything related.

How to run perl?

Postby mahes » 05. March 2008 08:30

Hi friends,

Am using PHP+Xampp. and i want to run a perl script using xampp?. what i do?
How do i change the configuration?
Posts: 20
Joined: 04. February 2008 10:47

Postby Scory » 05. March 2008 11:34

You don't need to change anything, Perl is included in Xampp. You simply must write a Perl Script, store it in cgi-bin folder and start in browser via http://localhost/cgi-bin/script.cgi

The first line of the script MUST be the so called "shebang" line, a comment line which points to the executable module of the Perl interpreter. Something like that:

Code: Select all

Xampp comes with a "Mini-Perl" installation (i dont know if the above path is correct - you must look for it), but you may install any full Perl Intepreter instead and replace the first line in your scripts, for example:

Code: Select all

"ActivePerl" is most popular and free for Windows. If you are working in a Linux environment, you may use the Linux perl programm instead, what results in this shebang line:

Code: Select all

Most important is, that you store the scripts in cgi-bin folder. Read the docu about "ScriptAlias"-Directive of Apache and edit httpd.conf, if you want to change the default cgi folder.


Return to XAMPP for Windows

Who is online

Users browsing this forum: No registered users and 78 guests