#!/usr/bin/perl
# ldap_schema.cgi
# LDAP Services ldap schema
# STTA Rev. 1.3 Copyright (c) 2001-2004 Jesús Pérez Lorenzo  --- license GNU GPL 
# stta: (@#) 1.31051043346- [2004_01_29_102036]

 require './stta-lib.pl';
do "ldap-lib.pl";
&ReadParse();

&headerstta($text{'index_ldapschema'}, "", "ldapschema",undef,1,0,"$text{'headpage_right'}"."$text{'head_logout'}",undef,undef,"$text{head_below}" );

        $ldap_server=$in{server} || "1";
        &connect();

 print "<hr><p>\n"; 
 print "<table width=100% border>\n";
 print "<tr $tb> <td><font color='$revtext'><b>$text{'titidx_ldapschema'}</b></td> </tr>\n";
if ( "$ldap_server" eq "1" ) {
         $line_tit=$config{ldap_servertitle};
         $line_conn=$config{LDAP_type}.":".$config{ldap_server}.":".$config {ldap_port};
  } elsif ( "$ldap_server" eq "2" ) {
         $line_tit=$config{ldap2_servertitle};
         $line_conn=$config{LDAP_type}.":".$config{ldap2_server}.":".$config {ldap2_port};
}
        $schema = $ldapObj->schema();
       print "<tr $cb><td valign=top><b><big>$line_tit ----  </big></b></i>$line_conn</i></td></tr>";
       print "<tr $cb> <td><table width=100% border>\n";
       print "<tr><td valign=top>CLASS</td><td valign=top> VALUE </td></tr>";
       &schema_dump("classes");
 print "<tr>\n";
 print "<tr>\n";
 print "</table></table><p>\n";
 &footer($text{'back_return'},$text{'index'});
 do "footer.pl";
 exit;
