Initial add of defaria.com
[clearscm.git] / defaria.com / cvsadm / select_server.cgi
1 #!/usr/bin/perl
2 ################################################################################
3 #
4 # File:         cvsadm/select_server.cgi
5 # Description:  Provides server selection
6 # Author:       Andrew@DeFaria.com
7 # Created:      Thu Jul  7 16:54:07 PDT 2005
8 # Modified:
9 # Language:     Perl
10 #
11 # (c) Copyright 2005, Andrew@DeFaria.com, all rights reserved.
12 #
13 ################################################################################
14 use strict;
15 use warnings;
16
17 use CGI qw (:standard *table start_Tr end_Tr start_td end_td start_div end_div);
18 use CGI::Carp "fatalsToBrowser";
19 use CVSAdm;
20
21 sub Body {
22   my %cvs_servers = CVSServers;
23   my @cvs_servers = sort keys (%cvs_servers);
24
25   print start_table {
26     -align              => "center",
27     -bgcolor            => "white",
28     -border             => 0,
29     -cellspacing        => 0,
30     -cellpadding        => 2,
31     -width              => "30%"};
32
33   print start_Tr;
34   print start_td {
35     -valign => "middle",
36     -class  => "label"};
37   print "CVS Server:";
38   print end_td;
39   print start_form {
40     -action => "select_repository.cgi"
41   };
42   print start_td {
43     -valign     => "middle"
44   };
45   print popup_menu {
46     -name       => "cvs_server",
47     -values     => \@cvs_servers,
48     -class      => "inputfield"
49   };
50   print " ";
51   print submit {
52     -name => "Select"
53   };
54   print end_td;
55   print end_form;
56   print end_table;
57 } # Body
58
59 Heading (
60          "",
61          "",
62          "CVSAdm: Select Server",
63          "CVS Administration Select Server",
64          "Please select a server to manage"
65 );
66
67 Body;
68 Footing;
69
70 exit;