GetDotted Domains

Viewing Thread:
"Urusei Machie"

The "Freeola Customer Forum" forum, which includes Retro Game Reviews, has been archived and is now read-only. You cannot post here or create a new thread or review on this forum.

Sat 18/11/06 at 21:41
Regular
Posts: 19,415
This is where I post problems and questions while I work on my Language/Travel website.

Link coming soon =)
Thu 23/11/06 at 23:28
Regular
Posts: 19,415
Thanks Garin and cjh.

I had a quick look at the poll, nice, results were on the same page though. Which isnt bad just more complicated I would have though. And I'm having problems with more simple scripts it seems.

.

god I hate Matt, I can't even get the clock to work. I installed and 755 the pl page and put it in the cgi-bin folder, but my index page isnt displaying it. :/
Thu 23/11/06 at 23:59
Regular
"Devil in disguise"
Posts: 3,151
Well, cant offer much assistance without seeing anything... Are you calling the cgi in the same manner as you've called other scripts you're using? Also check the error logs of your host, most cgi problems will appear in there (assuming you have access to them).
Fri 24/11/06 at 00:10
Regular
Posts: 19,415
Garin wrote:
> Well, cant offer much assistance without seeing anything... Are
> you calling the cgi in the same manner as you've called other
> scripts you're using? Also check the error logs of your host,
> most cgi problems will appear in there (assuming you have access
> to them).

I got these from the error log

[Thu Nov 23 23:11:46 2006] [error] [client 86.128.211.76] Premature end of script headers: /home/CENSORED/public_html/cgi-bin/textclock.pl

[Thu Nov 23 22:51:25 2006] [error] [client 86.128.211.76] File does not exist: /home/CENSORED/public_html/404.shtml


thought I should censor my username.

----

This is the index;

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<meta name="keywords" content=" " />
<meta name="description" content=" " />
<title>Learn The Language</title>
</head>
<body>
<!--#exec cgi="/cgi-bin/textclock.cgi"-->
</body>
</html>


I placed this perl script in my cgi-bin/ folder. I'm hoping the !/user/ part is correct for dataflame.

#!/usr/local/bin/perl
[SNIPPED OUT MATTS COMMENTS]
# Define Variables #

$Display_Week_Day = '1';

$Display_Month = '1';

$Display_Month_Day = '1';

$Display_Year = '1';

$Display_Time = '0';

$Display_Time_Zone = '0';

$Standard_Time_Zone = 'EST';
$Daylight_Time_Zone = 'EDT';

$Display_Link = '0';

# Done
#

@Week_Days = ('Sunday','Monday',
'Tuesday','Wednesday',
'Thursday','Friday','Saturday');

@Months = ('January','February',
'March','April'
,'May','June','July',
'August','September','October'
,'November','December');


print "Content-type: text/html\n\n";

if ($Display_Link != 0) {
print "<a href=\"http://www.scriptarchive.com/\">";
}

($Second,$Minute,$Hour,$Month_Day,
$Month,$Year,$Week_Day,$IsDST) = (localtime)[0,1,2,3,4,5,6,8];

if ($IsDST == 1) {
$Time_Zone = $Daylight_Time_Zone;
}
else {
$Time_Zone = $Standard_Time_Zone;
}

if ($Second < 10) {
$Second = "0$Second";
}
if ($Minute < 10) {
$Minute = "0$Minute";
}
if ($Hour < 10) {
$Hour = "0$Hour";
}
if ($Month_Day < 10) {
$Month_Day = "0$Month_Day";
}
$Year += 1900;

if ($Display_Week_Day != 0) {
print "$Week_Days[$Week_Day]";
if ($Display_Month != 0) {
print ", ";
}
}

if ($Display_Month != 0) {
print "$Months[$Month] ";
}

if ($Display_Month_Day != 0) {
print "$Month_Day";
if ($Display_Year != 0) {
print ", ";
}
}

if ($Display_Year != 0) {
print "$Year";
if ($Display_Time != 0) {
print " - ";
}
elsif ($Display_Time_Zone != 0) {
print " ";
}
}

if ($Display_Time != 0) {
print "$Hour\:$Minute\:$Second";
if ($Display_Time_Zone != 0) {
print " ";
}
}

if ($Display_Time_Zone != 0) {
print "$Time_Zone";
}

if ($Display_Link != 0) {
print "</a>";
}

exit;
Fri 24/11/06 at 00:11
Regular
Posts: 19,415
Oops had to mess up the months coding because of the 60 letter limit.
Fri 24/11/06 at 00:34
Regular
"Devil in disguise"
Posts: 3,151
Would I be right in asssuming you've already corrected the differing file extensions on the clock script?

The most likely cause of "Premature end of script headers" is file permissions. The script itself is fine (of course). Welcome to CGI and its lousy error reporting. :-)
Fri 24/11/06 at 00:39
Regular
Posts: 19,415
heh, yes I chm-something-or-other it. 755, I remembered changing them like that when I dealt with perl 10 years ago :)

hmm perhaps I should DF if #!/usr/local/bin/perl is the correct path, and the bit. Is it suppose to call up the file as a .cgi file and not a .pl file?
Fri 24/11/06 at 00:57
Regular
"Devil in disguise"
Posts: 3,151
Machie wrote:
> hmm perhaps I should DF if #!/usr/local/bin/perl is the correct
> path,

If the dataflame server you're on has cpanel installed, you can find the correct path to perl under General Server Information. On mine its /usr/bin/perl

> and the

Freeola & GetDotted are rated 5 Stars

Check out some of our customer reviews below:

10/10
Over the years I've become very jaded after many bad experiences with customer services, you have bucked the trend. Polite and efficient from the Freeola team, well done to all involved.
Second to none...
So far the services you provide are second to none. Keep up the good work.
Andy

View More Reviews

Need some help? Give us a call on 01376 55 60 60

It appears you are using an old browser, as such, some parts of the Freeola and Getdotted site will not work as intended. Using the latest version of your browser, or another browser such as Google Chrome, Mozilla Firefox, or Opera will provide a better, safer browsing experience for you.