Problemet är att jag inte förstår mig på att ställa in allt rätt för att få det att fungera. Ett annat i coh för sig säkert bra liknande script fick jag att fungera, så något problem med webhotellet är det inte. Jag kan dock inte köra cgiscript utanför cgi-bin katalogen, men i hjälp-/readmefilen förklaras hur man då skall gå tillväga. Jag klistrar in allt nedan istället och hoppas på vägledning, säkert inte alltför komplicerat för den som är van vid cgiscript men jag får inte till det.
csRecommend easily allows your visitors to recommend your site to their
family and friends.
Requirements:
1. Perl 5.005 or higher.
2. Unix based operating system (Unix, Linux, FreeBSD, etc).
Installation:
1. Unzip the file and transfer to your server with the following
directory structure:
/cgi-script <-- cgiscript.net script directory
/cgi-script/csRecommend <-- csRecommend directory
/cgi-script/csRecommend/images <-- image directory.
/cgi-script/csRecommend/export <-- export directory.
In most cases, the script is already configured. Change the $username and
$password variables to your liking and click 'Save'. If the setup portion
of the script cannot find your sites variables automatically, you will might
have to enter those in the above text area.
CGI-BIN Installation Instructions:
If your hosting service will not let your run scripts outside your cgi-bin
directory, then follow these procedures:
Copy all the *.cgi files to a directory in your cgi-bin directory, making
sure they are chmod'd to 755. For example, you could create a
/cgi-bin/csRecommend/ directory and place csRecommend.cgi, libs.cgi, and
setup.cgi if this file exists.
Create a directory outside your cgi-bin directory and copy all the remaining
files and subdirectories there. For example, you could create a
/cgi-script/csRecommend and place the files there.
Edit the above variables (or manually edit setup.cgi) to the following:
$cgiurl = URL to the csRecommend directory INSIDE
your cgi-bin directory (where the script is installed).
$cgipath = FULL PATH to the csRecommend directory INSIDE your cgi-bin
directory (where the script is installed).
ADD THE FOLLOWING VARIABLES TO THE ABOVE CONFIGURATION OR MANUALLY EDIT setup.cgi:
$htmlurl = FULL URL to the csRecommend directory OUTSIDE your cgi-bin
directory (where the remaining files where installed)
$htmlpath = FULL PATH to the csRecommend directory OUTSIDE your cgi-bin
directory (where the remaining files where installed)
For Example, your new setup.cgi file might look something like this:
$cgiurl='http://www.cgiscript.net/cgi-bin/csRecommend';
$cgipath='/www/vhosts/cgiscript.net/cgi-bin/csRecommend';
$sendmail = '/usr/sbin/sendmail';
$htmlurl='http://www.cgiscript.net/cgi-script/csRecommend';
$htmlpath='/www/vhosts/cgiscript.net/cgi-script/csRecommend';
$username='myusername';
$password='mypassword';
1;
(note: the '1' at the end is to prevent errors from perl if $password was left empty)
ALSO NOTE: If you keep getting the automatic setup screen, then chances are your web
server doesn't have write access to the csRecommend directory. To work around this, chmod
the csRecommend directory and all subdirectories to '777'.
INSTRUCTIONS:
Go to: http:///csRecommend.cgi where URL is the location of csRecommend.cgi on your server
Enter your username and password in the login screen
Follow the instructions on the management screen. In the text field for the message to send
out, you can specify the following values entered on the recommend form:
Your name: FORM(yourname)
Your email address: FORM(youremail)
Friend's name: FORM(friendsname)
Friend's email: FORM(friendsemail)
Comments: FORM(comments)
INSTRUCTIONS TO DISPLAY THE FORM ON YOUR WEBSITE.
In the control panel, click the 'Master Links' button. There are 2 types of links you can
use. One for a text link and one for a button. Cut and paste the appropriate code
on to your webpage.
--------
If you have any comments, questions, concerns or new script ideas go
to http://www.cgiscript.net and submit Contact Form. Installation
is available.
Ett exempel på vad jag inte förstår är vad katalogen /vhosts/ står för och varför den behövs. Men som sagt hur ska jag göra för att kunna använda detta gratisscript?
vhost är bara exempel på katalognamn hur det kan se ut på servern. Variablerna med namn som innehåller path används av scriptet för att läsa från/skriva till filer och variabler med namnet *url används för länkning från scriptet (det som du senare ser i webbläsaren).
Exakt vad är det som ställer till problem eller som du inte förstår?*
Gissar att vhosts står för "virtualhosts" eller något ditåt.
Det har gått framåt lite grand se'n senast.
Nu kommer jag till en sorts inloggningssida där det finns två knappar en Save och en Enter Management. Har sett att då jag klickar på Save, skapas filen setup.cgi. Problemet nu är förbryllande eftersom då jag uppdaterar sidan försvinner innehållet och tycks inte gå att få upp igen med mindre att jag ftp:ar upp alla *.cgi filerna igen. Likaså då jag klickar på knappen Enter Management så försvinner allt innehåll och sidan blir "vit".
Nja jag vet inte riktigt hur jag ska svara på det eftersom jag egentligen inte förstår någonting. Det jag försöker göra är att följa anvisningarna till scriptet och hoppas på det bästa. Jag frågade webhotellet tidigare idag och den som svarade sade att jag nog hade glömt ladda upp filen demolib.cgi. Det hade jag också gjort, vilket är fixat nu men med samma nedslående resultat.
Efter en prydlig "Configure Setup"- sida med bl. a. ovanstående hjälptext blir som sagt sidan "vit" efter att ha uppdaterats en gång och källkoden visar då detta på sitt vis:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=windows-1252"></HEAD>
<BODY></BODY></HTML>