Solved

stupid question II

Posted on 1998-12-09
4
165 Views
Last Modified: 2010-03-05
Now that I have the tutorials (please see original "stupid question"), what all do I need to begin writing perl scripts?

I am using Windows 98, but I am not sure what OS the server I will be uploading to is running.  I have very little info about the server...does it need a special program running in order to utilize perl scripts?  Or do you upload an executable?  Like I said I know very little about perl so these questions are going to appear to be very stupid to the likes of b2pi and ozzy and the other perl gurus.
0
Comment
Question by:scrapdog
[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
  • 2
  • 2
4 Comments
 
LVL 19

Accepted Solution

by:
cheekycj earned 30 total points
ID: 1206797
You need the following:

1. Editor-  You can use any text editor to create the scripts-  notepad, etc.

2. Perl Compiler(for win32)-  Download from http://www.activestate.com/pw32
the compiler there.  Once you download it - Install it.

3. To test the files locally you need a server on your local machine.  Win98 comes with
Personal Web Server that should work or you can download a free webserver from the
following:
http://www.sambar.com  (my preference because its very easy to use)
http://www.apache.org    (most widely used)  
http://www.omnicron.ab.ca/httpd/index.html  (a nice and small server)

once you have the server up and running and set it to run perl (should be in the server docs)
You should be good to go.

couple of tips.
to debug/run a script you have to do the following
either put path to perl in you autoexec.bat or do the following to compile/run:

<complete path to perl.exe> <complete path to perl script file>

Also you will need the #<path to perl.exe on your computer>  as the first line
of each script.

<<<the complete other way is that if your ISP allows you to do cgi scripting you can
write your scripts in notepad and upload the files to the server and then run perl. but
this is a long and tedious way.>>>

Happy programming!

Hope this helps

CJ
0
 
LVL 19

Expert Comment

by:cheekycj
ID: 1206798
Also to upload the scripts onto your server (once you have them working locally)
you will probably need to make the following modifications to your script files (extensions
cgi or pl)

First you will use your ISP's perl compiler (Its hard to find an ISP that doesn't have one)
to do that change the first line to the location of perl on your server rather than your local PC (ask the ISP about the perl location path)

probably change some of the paths in your scripts itself- if you are using any mail
programs or unix date commands.

Also when you ftp the files (cgi or pl files) to your cgi-bin directory on your server make sure you
ftp as ASCII only (not automatic) so it doesn't ftp the carriage returns that PC's add
on at the end as Perl in unix doesn't like them.


One last thing-  when you are using notepad or whatever to create the scripts save them
as-  .pl  or  .cgi

CJ
0
 
LVL 5

Author Comment

by:scrapdog
ID: 1206799
Adjusted points to 30
0
 
LVL 5

Author Comment

by:scrapdog
ID: 1206800
Excellent.  Thanks!
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

On Microsoft Windows, if  when you click or type the name of a .pl file, you get an error "is not recognized as an internal or external command, operable program or batch file", then this means you do not have the .pl file extension associated with …
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…

749 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