///Installing Scripts – Don’t be Scared!

Installing Scripts – Don’t be Scared!

Installing Scripts – Intro.

One of the biggest problems that I had when I set up my first site was essentially that I had no idea what I was doing. This manifested itself most obviously when it came to installing scripts for my site. I’m not a programmer (far from it) and I thought there would be assumed knowledge when it came to getting things running – knowledge that I assumed I didn’t have. Once I decided to give it a go (and stop paying people to do it for me) I realised that it’s actually pretty easy.

The majority of scripts that you download on the internet have pretty detailed instructions and if you follow these instructions, you’ll be done in a matter of minutes. Occasionally you’ll find scripts that do assume that you know what you are doing but even these are relatively simple.

My experience is in installing cgi scripts (usually Perl) on Unix machines which is what I’ll discuss here. The first step is downloading and (usually) unzipping the script. To unzip it, all you need is WinZip (http://www.winzip.com/) (or something like it). You will then be presented with the scripts, maybe some other files and the instructions – probably in a ReadMe file.

Read The Instructions

READ THE INSTRUCTIONS. I’m one of those people who never reads the instructions when I buy something new – I think I know what I’m doing, mess around, get annoyed and then finally decide to find out what I should really be doing. With scripts, just read the instructions first – everything will be much easier this way.

All that is really required is to ftp the scripts to your cgi-bin – I set up an individual folder in my cgi bin for each script. Some instructions doin’t really explain this but it’s much easier to do this for maintainance reasons and to avoid conflicts between scripts with the same file names. If you have a website, you should already know how to ftp stuff. If you don’t, download an ftp program such as WS_FTP (http://www.wsftp.com/) or CuteFTP (http://www.cuteftp.com/) – they are simple to use.

Once you’ve uploaded the files to correct places, the major thing that you will need to do is deal with file permissions. What this refers to is setting what can be done to each file – read, write and execute. There is a bit more to it but at this point, you don’t really need to know what it’s for, you just need to know how to do it. Again, your instructions should explain this but a general rule to follow is that any folders that you need to set up for the script will need to have permissions set at 777 (rwxrwxrwx), .cgi files are generally 755 (rwxr-xr-x) and things like database and html files tend to be 666 (rw-rw-rw-). This is just a guide – please make sure that these permissions are correct for your script.


Now this process may be called CHMOD in your instructions – it can be done if you telnet into your site and use Unix commands. If you are new to this, you probably have no idea what this means but don’t worry, you can change permissions on your files with an ftp program like the two I mentioned above and probably most others. In CuteFTP, you just right click on the file you want to alter and select CHMOD from the menu – I think WS_FTP works the same way. CuteFTP allows you to just type in the number (i.e. 777). You will see that there are three types of permissions – owner, group and public. To help out CHMOD 777 is read, write and execute for all, 755 is read all, write for owner only and execute for all and 666 is read and write for all.

On some occasions, there will also be a configuration file that you need to make changes to. This will often be a file with a .cfg extension. Your instructions may tell you to change some things here – just follow the instructions and you will be fine. This is usually just paths to the scripts, e-mail addresses and so on. By the way, the path to your script is the full system path – this will usually show up in your ftp window. Ask your hosts if you don’t know what it is.

Path To Perl Wraps It Up

The only other thing you need to know are your path to Perl and path to sendmail. Most scripts will probably have this set up correctly but if you need to change this, get the info from your hosts. Any good host will have this info available at their site.

I would recommend that you download a free script from somewhere and install it for practice. Try Advance Logger (http://www.perlonline.com) – there’s a free version and it’s easy to install.

This may not have made the process seem to much simpler, but believe me, for basic scripts it’s easy and it’s something you should learn to save money and give you more control over your site.

2010-05-26T17:11:21+00:00 October 14th, 2003|CGI and Perl|0 Comments

About the Author:

Sean Burns is the author of the WebmastersReference.com Newsletter - http://www.webmastersreference.com/newsletter. More than five years of experience in site design, marketing, income generation, search engine optimisation and more is passed on to subscribers - hype free. Sign up today to get real information of real value to webmasters.

Leave A Comment