Solved

how to install Perl?

Posted on 1998-12-07
11
253 Views
Last Modified: 2012-05-04
I am learning Perl, I bought 2 books but I can't figure out how I install Perl on my computer. My OS is NT4.
Right now I can only test my scripts through my ISP server (unix) and it's boring because it doesn't really work like they explain in the books (where you are supposed to have Perl installed on your computer).

Can someone explain exactly in details what to do, I really start from scratch, have no compiler, don't know if I need one, don't know where I find one... the real beginner so please, be patient and nice with me.

Thanks
0
Comment
Question by:wirefram
  • 5
  • 5
11 Comments
 
LVL 5

Expert Comment

by:Christian_Wenz
ID: 1206772
first, try to download the Win32-Port of Perl, if you haven't already (http://www.activestate.com/pw32, the section with the "316 build").
Then, install a Web Server on your machine. I prefer OmniHttpd, a very small server. (http://www.omnicron.ab.ca/httpd/index.html).

Please leave a comment as soon as you've installed this.
0
 
LVL 5

Expert Comment

by:Christian_Wenz
ID: 1206773
forgot to mention: download the free edition of the server
0
 
LVL 84

Expert Comment

by:ozo
ID: 1206774
ActiveState build 316 was based on Perl5.003, The current version is 5.005
You don't need a Web Server to run Perl, but you need one to run CGI
0
 

Author Comment

by:wirefram
ID: 1206775
I have everything installed. Looks good (@#!). Waiting for the sequel.

Thanks.

0
 

Author Comment

by:wirefram
ID: 1206776
Hello

About explaining what I do next?

I downloaded all the stuff, can you give me the explanation for what I do now?

Thanks

0
What Security Threats Are You Missing?

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

 
LVL 5

Expert Comment

by:Christian_Wenz
ID: 1206777
well, after downloading and installing OmniHttpd and perl, the omnihttpd symbol should be in the lower right corner of your screen (in the system tray). Right-Click on it and select Properties.
In the tab Advanced, write the filename and path of the Perl executable (eg. I have E:\PERL\BIN\PERL.EXE)
Be sure that both Process Server Side Includes and Enable Perl CGI support are checked.
Now, launch Netscape and access page localhost/Test.shtml. At the bottom of this page, fill out the form and press "Submit Saying". What does the next screen display?
0
 

Author Comment

by:wirefram
ID: 1206778
??? I don't have Netscape but Explorer and I don't have a folder called "localhost".

when I downloaded Omnihttpd, it has installed a folder called "httpd" on my computer. Inside I have 5 folders named exactly like that "Cgi-Bin", "Cgi-Win", "HtDocs", "Icons" and "Logs"
with the same exact capital letters.

Inside "HtDocs" there is a file called "test.shtml" title: CGI and SSI test, with a bunch of fields tests to fill. When I look at the source I see:

<a href="/cgi-bin/minimal.pl">Click here to test</a>

and if it refers to the cgi folder located in "httpd\Cgi-Bin" it cannot work because it's not the exact same name.

Do I have to rename everything?

When I select Properties in omnihttpd, I have  2 choices, Web server Virtual settings and Default virtual settings, in Web server, the Process SSI and Enable CGI are checked.

Do I have the right stuff?




0
 
LVL 5

Expert Comment

by:Christian_Wenz
ID: 1206779
no, I don'T think you have to rename anything. "localhost" or "127.0.0.1" is the server name of the omnihttpd server. I recommended Netscape for viewing as my IE sometimes needs that I have an active online connection in order to access the (locally stored) localhost server files.

So just try typing http://localhost/test.shtml  in you web browser's location field and tell me what you see...
0
 

Author Comment

by:wirefram
ID: 1206780
As I didn't have much luck with Omnihttpd, I downloaded Apache 1.3.3 and I was able to set it up.

Thanks for your help.

A last (?) question, help me with so I can close the question and give you my points.


When I write a script, to run it I use the command prompt window, is there a way to run it somehow else?

Can I run it in my browser without having to write "print content text html"  on the script?

To make it short, can my script behave the same in my browser than in the command prompt window?

Thanks



0
 
LVL 5

Accepted Solution

by:
Christian_Wenz earned 50 total points
ID: 1206781
as I understand it, no, sorry. A browser needs a "Content-type" when displaying a file (as a browser is file extension-independent). However, I think a "Content-type: text/html" and two line breaks are not spoiling the output of your program too much.

0
 

Author Comment

by:wirefram
ID: 1206782
Thanks
0

Featured Post

Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

Join & Write a Comment

Suggested Solutions

A year or so back I was asked to have a play with MongoDB; within half an hour I had downloaded (http://www.mongodb.org/downloads),  installed and started the daemon, and had a console window open. After an hour or two of playing at the command …
In the distant past (last year) I hacked together a little toy that would allow a couple of Manager types to query, preview, and extract data from a number of MongoDB instances, to their tool of choice: Excel (http://dilbert.com/strips/comic/2007-08…
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
This video discusses moving either the default database or any database to a new volume.

746 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

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now