Index: branches/htmlform/cgi-bin/admin.cgi
===================================================================
--- branches/htmlform/cgi-bin/admin.cgi	(revision 487)
+++ branches/htmlform/cgi-bin/admin.cgi	(revision 488)
@@ -243,25 +243,11 @@
 
 } elsif ($webvar{action} eq 'alloctweak') {
+
   fix_allocfrom();
   showAllocs($webvar{allocfrom});
+
 } elsif ($webvar{action} eq 'update') {
+
   update();
-} elsif ($webvar{action} eq 'assign') {
-  # Display a list of possible blocks within the requested block.
-  open (HTML, "../admin_alloc.html")
-	or croak "Could not open admin_alloc.html :$!";
-  my $html = join('', <HTML>);
-  $html =~ s/\$\$MASK\$\$/$webvar{masklen}/g;
-  $html =~ s/\$\$ALLOCFROM\$\$/$webvar{allocfrom}/g;
-
-  my $from = new NetAddr::IP $webvar{allocfrom};
-  my @blocklist = $from->split($webvar{masklen});
-  my $availblocks;
-  foreach (@blocklist) {
-    $availblocks .= qq(<tr><td colspan=2 align=center><input type=radio name=block value="$_">$_</td></tr>\n);
-  }
-  $html =~ s/\$\$BLOCKLIST\$\$/$availblocks/g;
-
-  print $html;
 
 } elsif ($webvar{action} eq 'touch') {
@@ -547,31 +533,4 @@
 
 
-# List free blocks in a /24 for arbitrary manual allocation
-sub showfree($) {
-  my $cidr = new NetAddr::IP $_[0];
-  print "Showing free blocks in $cidr<br>\n".
-	"<table border=1>\n";
-  $sth = $ip_dbh->prepare("select * from freeblocks where cidr <<= '$cidr' order by cidr");
-  $sth->execute;
-  while (my @data = $sth->fetchrow_array) {
-    my $temp = new NetAddr::IP $data[0];
-    print "<tr><form action=admin.cgi method=POST><input type=hidden name=action value=assign>\n".
-	qq(<td>$temp<input type=hidden name=allocfrom value="$temp"></td>\n).
-	"<td>".
-	(($temp->masklen == 30) ? '<input type=hidden name=masklen value=30>30'
-	  : "<select name=masklen><option>30</option>\n<option>29</option>\n") .
-	(($temp->masklen < 29) ? "<option>28</option>\n" : '') .
-	(($temp->masklen < 28) ? "<option>27</option>\n" : '') .
-	(($temp->masklen < 27) ? "<option>26</option>\n" : '') .
-	(($temp->masklen < 26) ? "<option>25</option>\n" : '') .
-	(($temp->masklen < 25) ? "<option>24</option>\n" : '') .
-	"</td>".
-	qq(<td>$data[2]</td><td><input type=submit value="Allocate from here"></td>).
-	"\n</form></tr>\n";
-  }
-  print "</table>\n";
-}
-
-
 # Show allocations to allow editing.
 sub showAllocs {
