Project

General

Profile

1
<?php
2
/*
3
*
4
*                       About WebsiteBaker
5
*
6
* Website Baker is a PHP-based Content Management System (CMS)
7
* designed with one goal in mind: to enable its users to produce websites
8
* with ease.
9
*
10
*                       LICENSE INFORMATION
11
*
12
* WebsiteBaker is free software; you can redistribute it and/or
13
* modify it under the terms of the GNU General Public License
14
* as published by the Free Software Foundation; either version 2
15
* of the License, or (at your option) any later version.
16
*
17
* WebsiteBaker is distributed in the hope that it will be useful,
18
* but WITHOUT ANY WARRANTY; without even the implied warranty of
19
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
20
* See the GNU General Public License for more details.
21
*
22
* You should have received a copy of the GNU General Public License
23
* along with this program; if not, write to the Free Software
24
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
25
*
26
*                   WebsiteBaker Extra Information
27
*
28
*
29
*/
30
/**
31
 *
32
 * @category        frontend
33
 * @package         account
34
 * @author          WebsiteBaker Project
35
 * @copyright       2004-2009, Ryan Djurovich
36
 * @copyright       2009-2010, Website Baker Org. e.V.
37
 * @link			http://www.websitebaker2.org/
38
 * @license         http://www.gnu.org/licenses/gpl.html
39
 * @platform        WebsiteBaker 2.8.x
40
 * @requirements    PHP 4.3.4 and higher
41
 * @version         $Id: login_form.php 1268 2010-01-22 17:21:02Z Luisehahne $
42
 * @filesource		$HeadURL: svn://isteam.dynxs.de/wb-archiv/branches/2.8.x/wb/account/login_form.php $
43
 * @lastmodified    $Date: 2010-01-22 18:21:02 +0100 (Fri, 22 Jan 2010) $
44
 *
45
 */
46

    
47
if(!defined('WB_URL')) die(header('Location: ../../index.php'));
48

    
49
$username_fieldname = 'username';
50
$password_fieldname = 'password';
51
	
52
if(defined('SMART_LOGIN') AND SMART_LOGIN == 'enabled') {
53
	// Generate username field name
54
	$username_fieldname = 'username_';
55
	$password_fieldname = 'password_';
56

    
57
	$temp = array_merge(range('a','z'), range(0,9));
58
	shuffle($temp);
59
	for($i=0;$i<=7;$i++) {
60
		$username_fieldname .= $temp[$i];
61
		$password_fieldname .= $temp[$i];
62
	}
63
}
64
?>
65
<h1>&nbsp;Login</h1>
66
&nbsp;<?php echo $thisApp->message; ?>
67
<br />
68
<br />
69

    
70
<form action="<?php echo WB_URL.'/account/login.php'; ?>" method="post">
71
<p style="display:none;"><input type="hidden" name="username_fieldname" value="<?php echo $username_fieldname; ?>" /></p>
72
<p style="display:none;"><input type="hidden" name="password_fieldname" value="<?php echo $password_fieldname; ?>" /></p>
73
<p style="display:none;"><input type="hidden" name="redirect" value="<?php echo $thisApp->redirect_url;?>" /></p>
74

    
75
<table cellpadding="5" cellspacing="0" border="0" width="90%">
76
<tr>
77
	<td style="width:100px"><?php echo $TEXT['USERNAME']; ?>:</td>
78
	<td class="value_input">
79
		<input type="text" name="<?php echo $username_fieldname; ?>" maxlength="30" style="width:220px;"/>
80
    	<script type="text/javascript">
81
    	// document.login.<?php echo $username_fieldname; ?>.focus();
82
    	var ref= document.getElementById("<?php echo $username_fieldname; ?>");
83
    	if (ref) ref.focus();
84
    	</script>
85
	</td>
86
</tr>
87
<tr>
88
	<td style="width:100px"><?php echo $TEXT['PASSWORD']; ?>:</td>
89
	<td class="value_input">
90
		<input type="password" name="<?php echo $password_fieldname; ?>" maxlength="30" style="width:220px;"/>
91
	</td>
92
</tr>
93
<?php if($username_fieldname != 'username') { ?>
94
<tr>
95
	<td>&nbsp;</td>
96
	<td>
97
		<input type="checkbox" name="remember" id="remember" value="true"/>
98
		<label for="remember"><?php echo $TEXT['REMEMBER_ME']; ?></label>
99
	</td>
100
</tr>
101
<?php } ?>
102
<tr>
103
	<td>&nbsp;</td>
104
	<td>
105
		<input type="submit" name="submit" value="<?php echo $TEXT['LOGIN']; ?>"  />
106
		<input type="reset" name="reset" value="<?php echo $TEXT['RESET']; ?>"  />
107
	</td>
108
</tr>
109
</table>
110

    
111
</form>
112

    
113
<br />
114

    
115
<a href="<?php echo WB_URL; ?>/account/forgot.php"><?php echo $TEXT['FORGOTTEN_DETAILS']; ?></a>
(7-7/14)