#!/usr/bin/perl

$tod = 900; # 1730

$title = "IETF 59 XCON Meeting Agenda";

print <<EOT
Content-Type: text/html

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

<pre>
Thursday, March 4 at 0900-1130
===================================

CHAIRS: Alan Johnston &lt;alan.johnston\@mci.com>
        Adam Roach &lt;adam\@dynamicsoft.com>

AGENDA:
</pre>

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

foreach $entry (<DATA>)
{
  chop;
  ($time, $name, $topic, $drafts, $presentations) = split(';', $entry);
  @drafts = split(',', $drafts);
  @presentations = split(',', $presentations);
  $start = $tod;
  $h = int($tod / 100);
  $m = $tod % 100;
  $m += $time;
  $h += int($m / 60);
  $m %= 60;
  $tod = $h*100 + $m;
  print "<TR>\n";
  print "  <TD>$start - $tod</TD>\n";
  print "  <TD>$time minutes</TD>\n";
  print "  <TD>$name</TD>\n";
  print "  <TD>$topic</TD>\n";
  print "  <TD>";
  foreach $draft (@drafts)
  {
    $draft =~ s/(.*)/<a href="\/xcon\/drafts\/$1">$1<\/a>/;
  }
  print join ("<BR>",@drafts);
  print "  </TD>\n";
  print "  <TD>";
  foreach $presentation (@presentations)
  {
    $presentation =~ s/([^.]*)\.(.*)/<a href="slides\/$1.$2">$2<\/a>/;
  }
  print join (", ",@presentations);
  print "  </TD>\n";
  print "</TR>\n";
}


print "</TABLE></CENTER></BODY></HTML>";

__DATA__
5;Chairs;Agenda Bash;;
10;Chairs;Milestone Review;draft-ietf-xcon-conference-scenarios-00.txt;chairs-xcon.ppt
15;Joerg Ott;Floor Control;draft-ietf-xcon-floor-control-req-00.txt;ott-fc.ppt
30;Hisham Khartabil;CPCP;draft-ietf-xcon-cpcp-reqs-02.txt,draft-koskelainen-xcon-xcap-cpcp-usage-02.txt;khartabil-cpcp.ppt
15;Eric Burger;Media Policy Models;draft-burger-xcon-mmodels-00.txt;burger-models.ppt
15;Cullen Jennings;Media Policy Templates;draft-jennings-xcon-media-control-00.txt;jennings-mpcp.ppt
60;All;Open Discussion;;
