server()) { metaRefresh("../login.php"); exit; } // empty list of attribute types $_SESSION['profile_types'] = array(); // print header echo $_SESSION['header']; echo "\n\n"; echo "
\n"; // check if account type is valid $type = $_GET['type']; if (!(($type == 'user') || ($type == 'group') || ($type == 'host'))) meta_refresh('profilemain.php'); // get module options $options = getProfileOptions($type); // load old profile if needed $old_options = array(); if ($_GET['edit']) { $old_options = loadAccountProfile($_GET['edit'], $type); } // display formular echo ("
\n"); // suffix box // get root suffix $rootsuffix = $_SESSION['config']->get_Suffix($type); // get subsuffixes $suffixes = array(); foreach ($_SESSION['ldap']->search_units($rootsuffix) as $suffix) { $suffixes[] = $suffix; } if (sizeof($suffixes) > 0) { echo "
\n" . _("LDAP suffix") . "\n"; echo _("LDAP suffix") . ":  "; echo "\n"; // help link echo " "; echo "\"""; echo "\n"; echo "
\n
\n"; } // index for tab order (1 is LDAP suffix) $tabindex = 2; $tabindexLink = 1000; // links are at the end // display module options $modules = array_keys($options); for ($m = 0; $m < sizeof($modules); $m++) { // ignore modules without options if (sizeof($options[$modules[$m]]) < 1) continue; echo "
\n"; echo "" . getModuleAlias($modules[$m], $type) . "\n"; $profileTypes = parseHtml($modules[$m], $options[$modules[$m]], $old_options, true, $tabindex, $tabindexLink, $type); $_SESSION['profile_types'] = array_merge($profileTypes, $_SESSION['profile_types']); echo "
\n"; echo "
"; } // profile name and submit/abort buttons echo ("" . _("Profile name") . ": \n"); $tabindex++; echo ("\n"); // help link echo ""; echo "\"""; echo "

\n"; $tabindex++; echo ("\n"); $tabindex++; echo ("\n"); $tabindex++; echo ("\n"); echo "\n"; echo ("
\n"); ?>