[Xitami] SSI problem....

Stephen S. Disbrow xitami@lists.xitami.org
Tue, 21 Dec 2004 23:42:45 -0500


This is a multi-part message in MIME format.

--Boundary_(ID_z33RHmsnCPvnh5nwWKFHnA)
Content-type: text/plain; charset=iso-8859-1
Content-transfer-encoding: 7BIT

Hello,

        I changed my default1 entry to point to index.shtml which is as follows;
<html>
<head>
<title>OUR FAMILY</title>
</head>

<body Text=#ffffff bgcolor="#000000">
<CENTER>
<BR><BR><BR>
<H1>
<MARQUEE>This page is under construction.</MARQUEE>
</H1>
<BR><BR><BR>
<!--#INCLUDE VIRTUAL="cgi-bin/time.pl"-->
</CENTER>
</body>
</HTML>


</html>

I placed my perl in cgi-bin time.pl it looks as follows;
#! /usr/bin/perl

$ENV{"TZ"} = "EST5EDT";
($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = localtime(time);
if ($hour >  12)
{
 $hour = $hour - 12;
 $ind = "PM";
}
elsif ($hour == 12)
{
 $ind = "PM";
}
elsif ($hour == 0)
{
 $hour = 12;
 $ind = "AM";
}
else
{
 $ind = "AM";
}
$day=(Sunday,Monday,Tuesday,Wednesday,Thursday,Friday,Saturday)[$wday];
$month=(January,February,March,April,May,June,July,August,September,October,November,December)[$mon];
print "Content-type: text/html\n\n";
printf ("%s %s %02d %4d, %02d:%02d %2s", $day, $month, $mday, (1900+$year), $hour, $min, $ind);

exit 0;

The problem is when  I attempt to open the page as localhost the system seems to hang for a long period of time I don't know what is wrong if anyone could tell me what's wrong I'd really appreciate it. I run the same shtml doc and cgi on a apache web server and it works perfect. Any help would really be appreciated.
I am running on WinXPHome  xitami-25 version as a service(xisrv32.exe);

Thank You,

Stephen S. Disbrow

Stephen S. Disbrow

--Boundary_(ID_z33RHmsnCPvnh5nwWKFHnA)
Content-type: text/html; charset=iso-8859-1
Content-transfer-encoding: 7BIT

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<META content="MSHTML 6.00.2900.2523" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT face=Arial size=2>Hello,</FONT></DIV>
<DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; I changed my default1 entry to point 
to index.shtml which is as follows;</DIV></DIV>
<DIV><FONT face=Arial size=2>&lt;html&gt;<BR>&lt;head&gt;<BR>&lt;title&gt;OUR 
FAMILY&lt;/title&gt;<BR>&lt;/head&gt;</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>&lt;body Text=#ffffff 
bgcolor="#000000"&gt;<BR>&lt;CENTER&gt;<BR>&lt;BR&gt;&lt;BR&gt;&lt;BR&gt;<BR>&lt;H1&gt;<BR>&lt;MARQUEE&gt;This 
page is under 
construction.&lt;/MARQUEE&gt;<BR>&lt;/H1&gt;<BR>&lt;BR&gt;&lt;BR&gt;&lt;BR&gt;<BR>&lt;!--#INCLUDE 
VIRTUAL="cgi-bin/time.pl"--&gt;<BR>&lt;/CENTER&gt;<BR>&lt;/body&gt;<BR>&lt;/HTML&gt;</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV><FONT face=Arial size=2>
<DIV><BR>&lt;/html&gt;</DIV>
<DIV>&nbsp;</DIV></FONT>
<DIV><FONT face=Arial size=2>I placed my perl in cgi-bin time.pl it looks as 
follows;</FONT></DIV>
<DIV><FONT face=Arial size=2>#! /usr/bin/perl</FONT></DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>$ENV{"TZ"} = 
"EST5EDT";<BR>($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = 
localtime(time);<BR>if ($hour &gt;&nbsp; 12)<BR>{<BR>&nbsp;$hour = $hour - 
12;<BR>&nbsp;$ind = "PM";<BR>}<BR>elsif ($hour == 12)<BR>{<BR>&nbsp;$ind = 
"PM";<BR>}<BR>elsif ($hour == 0)<BR>{<BR>&nbsp;$hour = 12;<BR>&nbsp;$ind = 
"AM";<BR>}<BR>else<BR>{<BR>&nbsp;$ind = 
"AM";<BR>}<BR>$day=(Sunday,Monday,Tuesday,Wednesday,Thursday,Friday,Saturday)[$wday];<BR>$month=(January,February,March,April,May,June,July,August,September,October,November,December)[$mon];<BR>print 
"Content-type: text/html\n\n";<BR>printf ("%s %s %02d %4d, %02d:%02d %2s", $day, 
$month, $mday, (1900+$year), $hour, $min, $ind);</FONT></DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>exit 0;<BR></FONT></DIV>
<DIV><FONT face=Arial size=2>The problem is when&nbsp; I attempt to open the 
page as localhost the system seems to hang for a long period of time I don't 
know what is wrong if anyone could tell me what's wrong I'd really appreciate 
it. I run the same shtml doc and cgi on a apache web server and it works 
perfect. Any help would really be appreciated.</FONT></DIV>
<DIV><FONT face=Arial size=2>I am running on WinXPHome &nbsp;xitami-25 version 
as a service(xisrv32.exe);</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>Thank You,</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>Stephen S. Disbrow</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>Stephen S. Disbrow<BR></FONT></DIV></BODY></HTML>

--Boundary_(ID_z33RHmsnCPvnh5nwWKFHnA)--