<?php
// $Horde: imp/scripts/custom_login.php,v 1.6.10.2 2005/10/18 12:14:06 jan Exp $

// CUSTOMIZE THIS
define('IMP_BASE', '..');

define('AUTH_HANDLER', true);
$authentication = 'none';
require_once IMP_BASE . '/lib/base.php';
require_once IMP_BASE . '/config/servers.php';

/* Set up the password encryption token. */
Secret::setKey('imp');

/* Use the first server defined in servers.php. */
// CUSTOMIZE THIS

$server_key = 'localhost';

$server_value = $servers[$server_key]['server'];
$protocol_value = $servers[$server_key]['protocol'];
$port_value = $servers[$server_key]['port'];
$maildomain_value = $servers[$server_key]['maildomain'];
$realm_value = $servers[$server_key]['realm'];
$url = '/';
// $url = '/' . $registry->get('initial_page','horde');

?>

<!-- CUSTOMIZE THIS -->
<form action="<?php echo Horde::applicationUrl('redirect.php') ?>" method="post">
User: <input name="imapuser" type="text" size="20" /><br />
Pass: <input name="pass" type="password" size="20" /><br />
<input type="hidden" name="server" value="<?php echo $server_value ?>" />
<input type="hidden" name="protocol" value="<?php echo $protocol_value ?>" />
<input type="hidden" name="port" value="<?php echo $port_value ?>" />
<input type="hidden" name="maildomain" value="<?php echo $maildomain_value ?>" />
<input type="hidden" name="realm" value="<?php echo $realm_value ?>" />
<input type="hidden" name="url" value="<?php echo $url ?>" />
<input type="submit" value="Log in" />
</form>
