phpldapadmin/htdocs/rename_form.php

42 lines
1.4 KiB
PHP
Raw Normal View History

2009-06-30 09:22:30 +00:00
<?php
2009-06-30 10:40:33 +00:00
// $Header: /cvsroot/phpldapadmin/phpldapadmin/htdocs/rename_form.php,v 1.10 2006/04/29 06:49:31 wurley Exp $
2009-06-30 10:26:08 +00:00
2009-06-30 09:29:51 +00:00
/**
2009-06-30 09:22:30 +00:00
* Displays a form for renaming an LDAP entry.
*
2009-06-30 09:29:51 +00:00
* Variables that come in via common.php
* - server_id
2009-06-30 09:22:30 +00:00
* Variables that come in as GET vars:
* - dn (rawurlencoded)
2009-06-30 09:29:51 +00:00
*
* @package phpLDAPadmin
*/
/**
2009-06-30 09:22:30 +00:00
*/
require './common.php';
2009-06-30 09:29:51 +00:00
if ($ldapserver->isReadOnly())
2009-06-30 10:26:08 +00:00
pla_error(_('You cannot perform updates while server is in read-only mode'));
2009-06-30 09:29:51 +00:00
if (! $ldapserver->haveAuthInfo())
2009-06-30 10:26:08 +00:00
pla_error(_('Not enough information to login to server. Please check your configuration.'));
2009-06-30 09:29:51 +00:00
2009-06-30 09:22:30 +00:00
$dn = $_GET['dn'];
2009-06-30 10:26:08 +00:00
$rdn = get_rdn($dn);
2009-06-30 09:22:30 +00:00
2009-06-30 10:26:08 +00:00
include './header.php';
2009-06-30 09:22:30 +00:00
2009-06-30 10:26:08 +00:00
echo '<body>';
printf('<h3 class="title">%s <b>%s</b></h3>',_('Rename Entry'),htmlspecialchars($rdn));
printf('<h3 class="subtitle">%s: <b>%s</b> &nbsp;&nbsp;&nbsp; %s: <b>%s</b></h3>',
_('Server'),$ldapserver->name,_('Distinguished Name'),htmlspecialchars($dn));
2009-06-30 09:22:30 +00:00
2009-06-30 10:26:08 +00:00
echo '<br /><center><form action="rename.php" method="post" class="edit_dn" />';
printf('<input type="hidden" name="server_id" value="%s" />',$ldapserver->server_id);
2009-06-30 10:40:33 +00:00
printf('<input type="hidden" name="dn" value="%s" />',htmlspecialchars($dn));
2009-06-30 10:26:08 +00:00
printf('<input type="text" name="new_rdn" size="30" value="%s" />',htmlspecialchars($rdn));
printf('<input class="update_dn" type="submit" value="%s" />',_('Rename'));
echo '</form></center>';
echo '</body></html>';
?>