[Last Call] Learn about multicloud storage options and how to improve your company's cloud strategy. Register Now

x
?
Solved

How do I run a perl script on win95 PC?

Posted on 1998-05-19
7
Medium Priority
?
212 Views
Last Modified: 2013-12-25
Hi.

I want to learn how to run perl scripts on my server!

I use win95. And have a directory called c:\perl with the perl.exe in.

Then in the cgi-bin directory of the server, I have made a new directory with the actual script in. called C:\progra~1\xitami\cgi-bin\fruitbbs
In that directory I have the perl script, wich starts with the line #!/usr/bin/perl - my Q now is; what do I do to make the script executet. When I open my htmlpage and press the button for calling the script, I get a view of the script instead.
0
Comment
Question by:CATT
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 3
7 Comments
 
LVL 28

Accepted Solution

by:
sybe earned 100 total points
ID: 1828841
1. the directory in which the perlscript is placed should be a virtual directory that is executable.
2. you have to let your webserver know that files with the extension .pl should be executed using perl.exe. How you do that depends on your server. If you use MS Personal webserver you have to edit the registry:
in:
[HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\W3Svc\Parameters\Script Map]

add:
.pl
with the value
C:\perl\bin\perl.exe %s

0
 

Author Comment

by:CATT
ID: 1828842
Great, thats what we needed to know, only problem now is that we do not use MS personal webserver, but the Xitami server. Do you know how to do it in that server? (could it be something in the mime editor?)
i'm willing to increase the points if thats what needed, as the script should be up and running within the next 8 days or so. So we really dont have that much time.

0
 
LVL 5

Expert Comment

by:icd
ID: 1828843
If you RTFM you can find the answer to this question. :-)

Look at http://www.imatix.com/html/xitami/index13.htm#c_5

which states:-

Quick hints on installing Perl for Windows    

Install Perl in some directory, and make sure the PATH includes the Perl bin directory. Define the PERLLIB environment variable to include the Perl lib directory
(this lets Perl find its library files). The command 'perl' must work when you're in a DOS box in the cgi-bin directory, and you must be able to run your Perl CGI
scripts using 'perl xxxx'. Then, check that the header of the CGI scripts start with '#! perl'.


Why does my Perl CGI not run?    

This is a check list that may help you.

   1.Did you install Perl? (Yes, some people forget this.)
   2.Can you run the CGI script from the DOS command line using the syntax 'perl scriptname'?
   3.Can you run the standard http://127.0.0.1/cgi-bin/testcgi program?
   4.Can you run a simple script like this:

     #! perl
     print "Hello World!";

   5.Does your CGI script start with '#! perl'?
   6.If you're running a 16-bit Perl, make sure Xitami is not in a subdirectory with long filenames (E.g. C:\Program Files\Xitami) or the CGI won't work. Under
     NT, forget 16-bit Perls completely.
   7.Finally, set the cgi:debug and server:debug options to 1. This will leave you with a couple of files in the temp directory- tempxxxx.cgo and header.log - that
     contain the actual CGI output and the headers sent back to the browser.
0
Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
LVL 5

Expert Comment

by:icd
ID: 1828844
If this works, please remember who 'answered' you question for you :-) (sorry sybe).

By the way sybe, how come I can't see your profile?

0
 
LVL 28

Expert Comment

by:sybe
ID: 1828845
icd: I don't know why you can't see my profile, i can see it :). And i can see yours.


0
 
LVL 5

Expert Comment

by:icd
ID: 1828846
sybe. I can see your profile now, must have been a glitch.

It appears that if an 'expert' has commented on a question they are no longer expected to pay to see the answer. That's a good change by EE.
0
 
LVL 28

Expert Comment

by:sybe
ID: 1828847
I noticed that too, it's a good thing !
0

Featured Post

Ask an Anonymous Question!

Don't feel intimidated by what you don't know. Ask your question anonymously. It's easy! Learn more and upgrade.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If you get a (Blue Screen of Death), your system writes a small file called a minidump. Your first step is to make certain your computer is setup to record memory dumps. Right click My Computer, choose properties. Click on the advanced tab, an…
This article is meant to give a basic understanding of how to use R Sweave as a way to merge LaTeX and R code seamlessly into one presentable document.
Learn how to match and substitute tagged data using PHP regular expressions. Demonstrated on Windows 7, but also applies to other operating systems. Demonstrated technique applies to PHP (all versions) and Firefox, but very similar techniques will w…
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…
Suggested Courses

656 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question