From: Steinar H. Gunderson
Date: Mon, 14 Feb 2005 18:22:30 +0000 (+0000)
Subject: Add an option for un-registering people.
X-Git-Url: https://git.sesse.net/?p=ccbs;a=commitdiff_plain;h=566480373f7e1f45b748c7a0f34dcfed5c318730;ds=inline
Add an option for un-registering people.
---
diff --git a/html/do-unregister.pl b/html/do-unregister.pl
new file mode 100755
index 0000000..3751e30
--- /dev/null
+++ b/html/do-unregister.pl
@@ -0,0 +1,18 @@
+#! /usr/bin/perl
+
+use ccbs;
+use strict;
+use warnings;
+
+my $dbh = ccbs::db_connect();
+my $cgi = new CGI;
+
+my $tournament = $cgi->param('tournament');
+my $player = $cgi->param('player');
+
+$dbh->do('DELETE FROM tournamentparticipation WHERE tournament=? AND player=?',
+ undef, $tournament, $player);
+
+ccbs::print_see_other('registration.pl?id=' . $tournament);
+
+$dbh->disconnect;
diff --git a/html/templates/registration.tmpl b/html/templates/registration.tmpl
index 539ccb6..5a2239f 100644
--- a/html/templates/registration.tmpl
+++ b/html/templates/registration.tmpl
@@ -60,6 +60,15 @@
+
+
+ |
[% END %]