annotate web/recent.cgi @ 8:7371f972393b

Import the /about web pages.
author John "Elwin" Edwards <elwin@sdf.org>
date Thu, 23 Aug 2012 10:50:35 -0700
parents 64272fc2350c
children 453278a81371
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
7
64272fc2350c Begin importing the website.
John "Elwin" Edwards <elwin@sdf.org>
parents:
diff changeset
1 #!/usr/bin/python
64272fc2350c Begin importing the website.
John "Elwin" Edwards <elwin@sdf.org>
parents:
diff changeset
2 # CGI script creating page of recent games
64272fc2350c Begin importing the website.
John "Elwin" Edwards <elwin@sdf.org>
parents:
diff changeset
3
64272fc2350c Begin importing the website.
John "Elwin" Edwards <elwin@sdf.org>
parents:
diff changeset
4 import sys
64272fc2350c Begin importing the website.
John "Elwin" Edwards <elwin@sdf.org>
parents:
diff changeset
5 import time
64272fc2350c Begin importing the website.
John "Elwin" Edwards <elwin@sdf.org>
parents:
diff changeset
6 import rlgall
64272fc2350c Begin importing the website.
John "Elwin" Edwards <elwin@sdf.org>
parents:
diff changeset
7
64272fc2350c Begin importing the website.
John "Elwin" Edwards <elwin@sdf.org>
parents:
diff changeset
8 # The required header
64272fc2350c Begin importing the website.
John "Elwin" Edwards <elwin@sdf.org>
parents:
diff changeset
9 sys.stdout.write("Content-type: text/html\r\n\r\n")
64272fc2350c Begin importing the website.
John "Elwin" Edwards <elwin@sdf.org>
parents:
diff changeset
10 # The top of the page
64272fc2350c Begin importing the website.
John "Elwin" Edwards <elwin@sdf.org>
parents:
diff changeset
11 sys.stdout.write(rlgall.phead.format("Recent Games"))
64272fc2350c Begin importing the website.
John "Elwin" Edwards <elwin@sdf.org>
parents:
diff changeset
12 sys.stdout.write(rlgall.ptop);
64272fc2350c Begin importing the website.
John "Elwin" Edwards <elwin@sdf.org>
parents:
diff changeset
13 sys.stdout.write(rlgall.navtop.format("Recent"));
64272fc2350c Begin importing the website.
John "Elwin" Edwards <elwin@sdf.org>
parents:
diff changeset
14 sys.stdout.write(rlgall.pti.format("Recent Expeditions"))
64272fc2350c Begin importing the website.
John "Elwin" Edwards <elwin@sdf.org>
parents:
diff changeset
15
64272fc2350c Begin importing the website.
John "Elwin" Edwards <elwin@sdf.org>
parents:
diff changeset
16 for game in rlgall.gamelist:
64272fc2350c Begin importing the website.
John "Elwin" Edwards <elwin@sdf.org>
parents:
diff changeset
17 game.tablerecent(sys.stdout)
64272fc2350c Begin importing the website.
John "Elwin" Edwards <elwin@sdf.org>
parents:
diff changeset
18
64272fc2350c Begin importing the website.
John "Elwin" Edwards <elwin@sdf.org>
parents:
diff changeset
19 sys.stdout.write(rlgall.pend)
64272fc2350c Begin importing the website.
John "Elwin" Edwards <elwin@sdf.org>
parents:
diff changeset
20 exit()