This commit is contained in:
ceb 2002-10-19 14:33:32 +00:00
parent cb2503a55b
commit e72d00ace1
3 changed files with 123 additions and 76 deletions

View File

@ -15,9 +15,10 @@
$phpgw_info = array(); $phpgw_info = array();
$GLOBALS['phpgw_info']['flags'] = array $GLOBALS['phpgw_info']['flags'] = array
( (
'login' => True, 'login' => True,
'currentapp' => 'login', 'currentapp' => 'login',
'noheader' => True 'noheader' => True,
'nodisplay' => True
); );
if(file_exists('./header.inc.php')) if(file_exists('./header.inc.php'))
@ -211,17 +212,27 @@
if ($GLOBALS['phpgw_info']['server']['show_domain_selectbox']) if ($GLOBALS['phpgw_info']['server']['show_domain_selectbox'])
{ {
$data['login_standard']['domain_select'] = True;
reset($phpgw_domain); reset($phpgw_domain);
unset($domain_select); // For security ... just in case
while ($domain = each($phpgw_domain)) while ($domain = each($phpgw_domain))
{ {
$domain_select .= '<option value="' . $domain[0] . '"';
if ($domain[0] == $last_domain) if ($domain[0] == $last_domain)
{ {
$domain_select .= ' selected'; $select = 'selected';
}
$data['login_standard']['domain_select'] = array
(
'domain' => $domain[0],
'selected' => $selected
);
}
for ($i=0;$i<count($data['login_standard']['domain_select']);$i++)
{
if ($data['login_standard']['domain_select'][$i]['selected'] != 'selected')
{
unset($data['login_standard']['domain_select'][$i]['selected']);
} }
$domain_select .= '>' . $domain[0] . '</option>';
} }
} }
@ -242,10 +253,13 @@
/*$GLOBALS['phpgw']->template->set_var('phpgw_head_base',$GLOBALS['phpgw_info']['server']['webserver_url'].'/'); /*$GLOBALS['phpgw']->template->set_var('phpgw_head_base',$GLOBALS['phpgw_info']['server']['webserver_url'].'/');
$GLOBALS['phpgw']->template->set_var('registration_url','registration/');*/ $GLOBALS['phpgw']->template->set_var('registration_url','registration/');*/
$data['login_standard']['website_title'] = $GLOBALS['phpgw_info']['server']['site_title'];
$data['login_standard']['msgbox'] = $GLOBALS['phpgw']->common->msgbox('',False); $data['login_standard']['msgbox'] = $GLOBALS['phpgw']->common->msgbox('',False);
$data['login_standard']['login_url'] = 'login.php' . $extra_vars; $data['login_standard']['login_url'] = 'login.php' . $extra_vars;
$data['login_standard']['cookie'] = show_cookie(); $data['login_standard']['cookie'] = show_cookie();
$data['login_standard']['lang_username'] = lang('username'); $data['login_standard']['lang_username'] = lang('username');
$data['login_standard']['lang_powered_by'] = lang('powered by');
$data['login_standard']['lang_version'] = lang('version');
$data['login_standard']['phpgw_version'] = $GLOBALS['phpgw_info']['server']['versions']['phpgwapi']; $data['login_standard']['phpgw_version'] = $GLOBALS['phpgw_info']['server']['versions']['phpgwapi'];
$data['login_standard']['lang_password'] = lang('password'); $data['login_standard']['lang_password'] = lang('password');
$data['login_standard']['lang_login'] = lang('login'); $data['login_standard']['lang_login'] = lang('login');

View File

@ -51,6 +51,14 @@ a:hover
width: 100%; width: 100%;
} }
.login
{
background-color: #80BBFF;
border-width: 1px;
border-color: #000000;
border-style: ridge;
}
.portal_text .portal_text
{ {
color: #FFFFFF; color: #FFFFFF;

View File

@ -13,10 +13,10 @@
<base target="_self"/> <base target="_self"/>
<link rel="icon" href="favicon.ico" type="image/x-ico"/> <link rel="icon" href="favicon.ico" type="image/x-ico"/>
<link rel="shortcut icon" href="favicon.ico"/> <link rel="shortcut icon" href="favicon.ico"/>
<title><xsl:value-of select="phpgw_website_title"/></title> <title><xsl:value-of select="phpgw_head_website_title"/></title>
<link rel="stylesheet" type="text/css" href="{$login_theme}"/> <link rel="stylesheet" type="text/css" href="{$login_theme}"/>
</head> </head>
<body bgcolor="#FFFFFF"> <body>
<xsl:apply-templates select="login_standard"/> <xsl:apply-templates select="login_standard"/>
</body> </body>
</html> </html>
@ -24,7 +24,7 @@
<xsl:template match="login_standard"> <xsl:template match="login_standard">
<xsl:variable name="login_layout"><xsl:value-of select="login_layout"/></xsl:variable> <xsl:variable name="login_layout"><xsl:value-of select="login_layout"/></xsl:variable>
<table cellpadding="0" cellspacing="0" width="40%" align="center"> <table cellpadding="0" cellspacing="0" width="100%" height="100%">
<tr> <tr>
<td> <td>
<a href="http://www.phpgroupware.org" target="_blank" onMouseout="window.status='';return true;"> <a href="http://www.phpgroupware.org" target="_blank" onMouseout="window.status='';return true;">
@ -37,70 +37,95 @@
</a> </a>
</td> </td>
</tr> </tr>
</table> <tr>
<table cellpadding="0" cellspacing="0" width="40%" align="center" class="th"> <td align="center"><xsl:value-of select="phpgw_loginscreen_message"/></td>
<xsl:choose> </tr>
<xsl:when test="loginscreen"> <tr>
<xsl:variable name="login_url"><xsl:value-of select="login_url"/></xsl:variable> <td valign="middle" align="center">
<xsl:variable name="cookie"><xsl:value-of select="cookie"/></xsl:variable> <table cellpadding="0" cellspacing="0" width="40%" class="login">
<xsl:variable name="lang_login"><xsl:value-of select="lang_login"/></xsl:variable> <xsl:choose>
<tr> <xsl:when test="loginscreen">
<td align="center"><xsl:value-of select="phpgw_loginscreen_message"/></td> <xsl:variable name="login_url"><xsl:value-of select="login_url"/></xsl:variable>
</tr> <xsl:variable name="cookie"><xsl:value-of select="cookie"/></xsl:variable>
<tr> <xsl:variable name="lang_login"><xsl:value-of select="lang_login"/></xsl:variable>
<td> <tr>
<table width="100%" cellpadding="2" cellspacing="1"> <td>
<tr class="th"> <table width="100%" cellpadding="2" cellspacing="1" class="login">
<td valign="middle"><b>phpGroupWare</b></td> <tr>
</tr> <td align="center"><b><xsl:value-of select="website_title"/></b></td>
<tr class="row_off"> </tr>
<td valign="bottom"> <tr class="row_off">
<form name="login" method="post" action="{$login_url}"> <td>
<input type="hidden" name="passwd_type" value="text"/> <form name="login" method="post" action="{$login_url}">
<table align="center" width="100%" cellpadding="2" cellspacing="2"> <input type="hidden" name="passwd_type" value="text"/>
<tr> <table align="center" width="100%" cellpadding="2" cellspacing="2">
<td colspan="3" align="center"><xsl:value-of disable-output-escaping="yes" select="msgbox"/></td> <tr>
</tr> <td colspan="3" align="center"><xsl:value-of disable-output-escaping="yes" select="msgbox"/></td>
<tr> </tr>
<td align="right"><xsl:value-of select="lang_username"/></td> <tr>
<td><input name="login" value="{$cookie}"/></td> <td width="33%" align="right"><xsl:value-of select="lang_username"/></td>
<xsl:choose> <td width="33%" align="center"><input name="login" value="{$cookie}"/></td>
<xsl:when test="domain_select"> <xsl:choose>
<td><select name="logindomain"><xsl:apply-templates select="select_domain"/></select></td> <xsl:when test="domain_select">
</xsl:when> <td><select name="logindomain"><xsl:apply-templates select="domain_select"/></select></td>
<xsl:otherwise> </xsl:when>
<td></td> <xsl:otherwise>
</xsl:otherwise> <td></td>
</xsl:choose> </xsl:otherwise>
</tr> </xsl:choose>
<tr> </tr>
<td align="right"><xsl:value-of select="lang_password"/></td> <tr>
<td><input name="passwd" type="password" onChange="this.form.submit()"/></td> <td align="right"><xsl:value-of select="lang_password"/></td>
<td></td> <td align="center"><input name="passwd" type="password" onChange="this.form.submit()"/></td>
</tr> <td></td>
<tr> </tr>
<td colspan="3" align="center"> <tr>
<input type="submit" value="{$lang_login}" name="submitit"/> <td colspan="3" align="center">
</td> <input type="submit" value="{$lang_login}" name="submitit"/>
</tr> </td>
</table> </tr>
</form> </table>
</td> </form>
</tr> </td>
<tr> </tr>
<td align="right" class="th"> <tr>
<xsl:value-of select="phpgw_version"/> <td align="center">
</td> <xsl:value-of select="lang_powered_by"/>
</tr> <a href="http://www.phpgroupware.org" target="blank" onMouseout="window.status='';return true;">
</table> <xsl:attribute name="onMouseover">
</td> <xsl:text>window.status='</xsl:text>
</tr> <xsl:value-of select="lang_phpgw_statustext"/>
</xsl:when> <xsl:text>'; return true;</xsl:text>
<xsl:otherwise> </xsl:attribute>
<tr> <xsl:text> phpGroupWare </xsl:text>
<td align="center">Opps! You caught us in the middle of a system upgrade.<br/>Please, check back with us shortly.</td> </a>
</tr> <xsl:text> </xsl:text><xsl:value-of select="lang_version"/><xsl:text> </xsl:text><xsl:value-of select="phpgw_version"/>
</xsl:otherwise> </td>
</xsl:choose> </tr>
</table>
</td>
</tr>
</xsl:when>
<xsl:otherwise>
<tr>
<td align="center">Opps! You caught us in the middle of a system upgrade.<br/>Please, check back with us shortly.</td>
</tr>
</xsl:otherwise>
</xsl:choose>
</table>
</td>
</tr>
</table> </table>
</xsl:template> </xsl:template>
<xsl:template match="domain_select">
<xsl:variable name="domain"><xsl:value-of select="domain"/></xsl:variable>
<xsl:choose>
<xsl:when test="selected">
<option value="{$domain}" selected="selected"><xsl:value-of select="domain"/></option>
</xsl:when>
<xsl:otherwise>
<option value="{$domain}"><xsl:value-of select="domain"/></option>
</xsl:otherwise>
</xsl:choose>
</xsl:template>