script problem

by Michael Muehlendorf <haoka(at)wi.tds.net>

 Date:  Mon, 06 Jan 2003 20:15:58 -0600
 To:  hwg-techniques(at)hwg.org
  todo: View Thread, Original
This is a cross-post:

Hello List -

I have a script on my site that prints the name of the month that follows
the current month. For some reason, it has stopped giving output. I am
pasting in the code below, and perhaps some of you perl gurus could steer
me in the right direction to find/fix the error? Otherwise, can someone
tell me how to accomplish the same thing with PHP? (Or can you mix
server-side includes and PHP on the same XHTML document?)
_________________________________________________________
#!/usr/bin/perl

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

$currmon = (localtime)[4];
$currmon == 11? $nextmon = 0: $nextmon = $currmon + 1;

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

print "<.b>$Months[$nextmon]<./b>\n";
_________________________________________________________

TIA and happy HTMLing,

Mike

Michael Jon Muehlendorf
Scenic Bluffs Webcrafters
http://www.scenic-bluffs.com/

HWG hwg-techniques mailing list archives, maintained by Webmasters @ IWA