#!/usr/bin/perl -s


$title = "IETF 61 XCON Meeting Timeslot Requests";

print <<EOT
Content-Type: text/html

<HTML><HEAD><TITLE>$title</TITLE></HEAD>
<BODY>
<H1>$title</h1>

<p>Note that the following table only indicates requests.
The actual agenda will be determined based on this input;
however, timeslots may be adjusted or removed depending
on a variety of factors.
<p>If you wish to request a timeslot, please send e-mail
to adam&#64;nostrum.com.

<CENTER><TABLE border=1>
<TR>
  <TH>Name</TH>
  <TH>Topic</TH>
  <TH>Draft</TH>
  <TH>Time Requested</TH>
EOT
;

foreach $entry (<DATA>)
{
  chop;
  ($name, $topic, $drafts, $time) = split(';', $entry);
  @drafts = split(',', $drafts);
  print "<TR>\n";
  print "  <TD>$name</TD>\n";
  print "  <TD>$topic</TD>\n";
  print "  <TD>";
  foreach $draft (@drafts)
  {
    if (-e "../../drafts/$draft")
    {
      $draft =~ s/(.*)/<a href="\/xcon\/drafts\/$1">$1<\/a>/;
    }
    else
    {
      if ($f)
      {
        system ("cd ../../drafts; wget http://www.ietf.org/internet-drafts/$draft");
      }
      $draft =~ s/(.*)/<a href="http:\/\/www.ietf.org\/internet-drafts\/$1">$1<\/a><sup>*<\/sup>/;
      $nonlocal++;
    }
  }
  print join ("<BR>",@drafts);
  print "</TD>\n";
  print "  <TD>$time</TD>\n";
}


print "</TABLE></CENTER>";
if ($nonlocal) {print "<br><sup>*</sup>Not on the local server";}
print "</BODY></HTML>\n";

__DATA__
Author;Subject;Draft;Time
