|
|||||||||||||||||||||||||||
Jeg har et script der hedder hejverden.pl
Jeg har uploadet det til min server, hvor jeg har lavet et cgi-bin til
det. Jeg har chmod 755 og uploadet som ascii
Jeg har perl-stien til at være: /usr/local/bin/perl
og i browseren adresselinie skriver jeg følgende:
loldrup.port5.com/cgi-bin/hejverden.pl
(mit subdomæne)
Dette er hvad udbyderen har skrevet til mig:
4. CGI
Tu use cgi, create a cgi-bin in your home directory. Upload .cgi and
pl files into that folder. Remember that they must be made
executeable before they will work.
Some CGI's need a full path name to work. Add /home/loldrup to the
path name.
perl version 5 = //usr/local/bin/perl
sendmail = /usr/lib/sendmail
perl-koden ser sådan ud:
#!/usr/local/bin/perl
print ("Content-type: text/html\n\n");
print "Hej Verden";
og jeg får følgende resultat, når jeg bruger følgende adresse i
browseren; http://loldrup.port5.com/cgi-bin/hejverden.pl
Internal Server Error
The server encountered an internal error or misconfiguration and was
unable to complete your request.
Please contact the server administrator, sslug@sslug and
inform them of the time the error occurred, and anything you might
have done that may have caused the error.
More information about this error may be available in the server error
log.
WebWasher - Error 503: Service Unavailable
The server is currently unable to handle the request due to a
temporary overloading or maintenance of the server.
The server 'loldrup.port5.com' (port 80) unexpectedly closed the
connection !
For further information please read the WebWasher help file or visit
our homepage at http://www.webwasher.com !
If you want to try again click here !
generated by WebWasher 1.2.2
(webwasher er en lokal proxy til at fjerne bannerreklamer. burde ikke
have noget med sagen at gøre)
Jeg har brugt følgende guide, og jeg kan ikke finde fejlen:
http://webcafe.dk/perl/artikler/004/pa004.php3
jeg har også afprøvet scriptet på en lokal apache server på win98. Det
virker.
hvad mener udbyderen med: "Some CGI's need a full path name to work.
Add /home/loldrup to the path name."
hvor vil de have at jeg skal tilføje den linie? I browserens
adressefelt, eller i stien til perl-programmet i selve scriptet? Jeg
har forsøgt at skrive det ind i browserens adressefeldt, sådan her:
portland.co.uk/home/loldrup/cgi-bin/hejverden.pl
(serveren uden brug af subdomæne)
med følgende resultat:
WebWasher - Error 500: Internal Server Error
The server encountered an unexpected condition which prevented it from
fulfilling the request.
Couldn't connect to server 'portland.co.uk' (port 80) !
Either the server is down or your network is not properly configured.
Maybe you have to use a proxy to connect to the internet. Perhaps your
modem is switched off / your network card disconnected or the address
wasn't entered correctly. Please check if the URL is correct.
If the problem persists you should contact your network administrator.
For further information please read the WebWasher help file or visit
our homepage at http://www.webwasher.com !
If you want to try again click here !
generated by WebWasher 1.2.2
jeg har også prøvet at sætte det ind for enden af stien til
perl-programmet, i selve scriptet, så det ser sådan ud:
http://loldrup.port5.com/cgi-bin/hejverden.pl
, med følgende resultat:
Internal Server Error
The server encountered an internal error or misconfiguration and was
unable to complete your request.
Please contact the server administrator, sslug@sslug and
inform th
serveren er ikke nede. så meget har jeg fundet ud af.
mvh Jon Loldrup - der har store problemer med sit advancerede
perl-script.
|
||||||||||||||
|
||||||||||||||