</table>
</div>
</div>
</div>
</div>
<?php
/**
* @version $Id: mod_login.php 2550 2006-10-02 00:25:34Z stingrey $
* @package Joomla
* @copyright Copyright (C) 2006 Joomla! Ukraine. All rights reserved.
* @license http://www.gnu.org/copyleft/gpl.html GNU/GPL, see LICENSE.php
* Joomla! is free software. This version may have been modified pursuant
* to the GNU General Public License, and as distributed it includes or
* is derivative of works licensed under the GNU General Public License or
* other free or open source software licenses.
* See COPYRIGHT.php for copyright notices and details.
*/
defined( '_VALID_MOS' ) or die( 'Restricted access' );
global $mosConfig_frontend_login;
if ( $mosConfig_frontend_login != NULL && ($mosConfig_frontend_login === 0 || $mosConfig_frontend_login === '0')) {
return;
}
$url = mosGetParam( $_SERVER, 'REQUEST_URI', null );
if ( strpos($url, 'http:') !== 0 && strpos($url, 'https:') !== 0 ) {
if (strpos($url, '/') !== 0) {
$url = '/'. $url;
}
$url = mosGetParam( $_SERVER, 'HTTP_HOST', null ) . $url;
if ( isset( $_SERVER['HTTPS'] ) && ( !empty( $_SERVER['HTTPS'] ) && $_SERVER['HTTPS'] != 'off' ) ) {
$return = 'https://'. $url;
} else {
$return = 'http://'. $url;
}
} else {
$return = $url;
}
$return = str_replace( '&', '&', $return );
$registration_enabled = $mainframe->getCfg( 'allowUserRegistration' );
$message_login = $params->def( 'login_message', 0 );
$message_logout = $params->def( 'logout_message', 0 );
$login = $params->def( 'login', $return );
$logout = $params->def( 'logout', $return );
$name = $params->def( 'name', 1 );
$greeting = $params->def( 'greeting', 1 );
if ( $my->id ) {
if ( $name ) {
$name = $my->name;
} else {
$name = $my->username;
}
?>
<form align="center" action="<?php echo sefRelToAbs( 'index.php?option=logout' ); ?>" method="post" name="logout">
<input type="submit" name="Submit" class="dgm_m_button_log" value="<?php echo _BUTTON_LOGOUT; ?>" /> || <? if ( $greeting ) {echo _HI;echo $name;}?>
<input type="hidden" name="op2" value="logout" />
<input type="hidden" name="lang" value="<?php echo $mosConfig_lang; ?>" />
<input type="hidden" name="return" value="<?php echo sefRelToAbs( $logout ); ?>" />
<input type="hidden" name="message" value="<?php echo $message_logout; ?>" />
</form>
<?php }
else { $validate = josSpoofValue(1); ?>
<script type="text/javascript" src="modules/dgmlogin/dgmlogin.js"></script>
<div align="right">
<table cellpadding="6" cellspacing="0" border="0" width="150" style="border-top-width:0px">
<tr align="center">
<td><span id="navbar_search"><a href="" accesskey="4" rel="nofollow">
<? echo _BUTTON_LOGIN;?></a></span>||
<?php
if ( $registration_enabled ) {
?>
<a href="<?php echo sefRelToAbs( 'index.php?option=com_registration&task=register' ); ?>">
<?php echo _CREATE_ACCOUNT; ?></a>
<?php
}
?>
<script type="text/javascript"> dgmmenu_register("navbar_search"); </script>
</td>
</tr>
</table>
</div>
<div class="dgmmenu_popup" id="navbar_search_menu" style="display:none">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="dgmmenu_option" title="nohilite">
<form action="<?php echo sefRelToAbs( 'index.php' ); ?>" method="post" name="login" >
<table width="100%" border="0" cellspacing="0" cellpadding="0" align="center" class="dgm_m_table">
<tr>
<td class="dgm_m_td_left">
<label for="mod_login_username">
<?php echo _USERNAME; ?>
</label>
<br />
<input name="username" id="mod_login_username" type="text" class="dgm_m_inputbox" alt="username" size="20" />
<br />
<label for="mod_login_password">
<?php echo _PASSWORD; ?>
</label>
<br />
<input type="password" id="mod_login_password" name="passwd" class="dgm_m_inputbox" size="20" alt="password" />
</td><td class="dgm_m_td_right">
<a href="<?php echo sefRelToAbs( 'index.php?option=com_registration&task=lostPassword' ); ?>">
<?php echo _LOST_PASSWORD; ?></a>
<br />
<input type="checkbox" name="remember" id="mod_login_remember" class="dgm_m_inputbox" value="yes" alt="Remember Me" />
<label for="mod_login_remember">
<?php echo _REMEMBER_ME; ?>
</label>
<br />
<input type="hidden" name="option" class="dgm_m_inputbox" value="login" />
<input type="submit" name="Submit" class="dgm_m_button" value="<?php echo _BUTTON_LOGIN; ?>" />
</td>
</tr>
</table>
<input type="hidden" name="option" value="login" />
<input type="hidden" name="op2" value="login" />
<input type="hidden" name="lang" value="<?php echo $mosConfig_lang; ?>" />
<input type="hidden" name="return" value="<?php echo sefRelToAbs( $login ); ?>" />
<input type="hidden" name="message" value="<?php echo $message_login; ?>" />
<input type="hidden" name="<?php echo $validate; ?>" value="1" />
</form>
</td>
</tr>
</table>
</div>
</div>
</div>
</div>
<?php } ?>
<div class="dgmmenu_popup" id="navbar_search_menu" style="display:none">
<div class="dgmmenu_popup" id="navbar_search_menu" style="display:none">
Time to create page: 0.070 seconds