Project

General

Profile

1
<?php
2

    
3
// $Id: index.php,v 1.6 2005/04/15 06:38:13 rdjurovich Exp $
4

    
5
/*
6

    
7
 Website Baker Project <http://www.websitebaker.org/>
8
 Copyright (C) 2004-2005, Ryan Djurovich
9

    
10
 Website Baker is free software; you can redistribute it and/or modify
11
 it under the terms of the GNU General Public License as published by
12
 the Free Software Foundation; either version 2 of the License, or
13
 (at your option) any later version.
14

    
15
 Website Baker is distributed in the hope that it will be useful,
16
 but WITHOUT ANY WARRANTY; without even the implied warranty of
17
 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18
 GNU General Public License for more details.
19

    
20
 You should have received a copy of the GNU General Public License
21
 along with Website Baker; if not, write to the Free Software
22
 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
23

    
24
*/
25

    
26
?>
27
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
28
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
29
<head>
30
<title><?php page_title(); ?></title>
31
<meta name="description" content="<?php page_description(); ?>" />
32
<meta name="keywords" content="<?php page_keywords(); ?>" />
33
<link href="<?php echo TEMPLATE_DIR; ?>/screen.css" rel="stylesheet" type="text/css" media="screen" />
34
<link href="<?php echo TEMPLATE_DIR; ?>/print.css" rel="stylesheet" type="text/css" media="print" />
35
</head>
36
<body>
37

    
38
<table cellpadding="0" cellspacing="0" border="0" align="center" class="main" width="750">
39
<tr>
40
	<td colspan="2" class="header" height="80">
41
		<a href="<?php echo WB_URL; ?>"><img src="<?php echo TEMPLATE_DIR; ?>/banner.jpg" border="0" width="750" height="80" alt="<?php page_title('', '[WEBSITE_TITLE]'); ?>" /></a>
42
	</td>
43
</tr>
44
<tr>
45
	<?php
46
	// Only show menu items if we are supposed to
47
	if(SHOW_MENU) {
48
	?>	
49
	<td style="padding: 10px; background-color: #FFFFFF;" valign="top">
50
		<table cellpadding="0" cellspacing="0" border="0" width="150" align="center" class="menu">
51
		<tr>
52
			<td class="border">
53
				<img src="<?php echo TEMPLATE_DIR; ?>/menu_top.gif" border="0" alt="" />
54
			</td>
55
		</tr>
56
		<tr>
57
			<td width="170">
58
				<?php page_menu(); ?>
59
			</td>
60
		</tr>
61
		<tr>
62
			<td class="border">
63
				<img src="<?php echo TEMPLATE_DIR; ?>/menu_bottom.gif" border="0" alt="" />
64
			</td>
65
		</tr>
66
		</table>
67
		
68
		<?php if(SHOW_SEARCH) { ?>
69
		<form name="search" action="<?php echo WB_URL.'/search/index'.PAGE_EXTENSION; ?>" method="post">
70
			<table cellpadding="0" cellspacing="0" border="0" width="150" align="center" style="margin-top: 10px;">
71
				<tr>
72
					<td class="border">
73
						<img src="<?php echo TEMPLATE_DIR; ?>/menu_top.gif" border="0" alt="" />
74
					</td>
75
				</tr>
76
				<tr>
77
					<td class="login">
78
						<input type="text" name="string" />
79
					</td>
80
				</tr>
81
				<tr>
82
					<td class="login">
83

    
84
						<input type="submit" name="submit" value="<?php if(isset($TEXT['SUBMIT'])) { echo $TEXT['SEARCH']; } else { echo 'Search'; } ?>" />
85
					</td>
86
				</tr>
87
				<tr>
88
					<td class="border">
89
						<img src="<?php echo TEMPLATE_DIR; ?>/menu_bottom.gif" border="0" alt="" />
90
					</td>
91
				</tr>
92
			</table>
93
		</form>
94
		<?php } ?>
95
		
96
		<?php
97
		if(FRONTEND_LOGIN AND !$admin->is_authenticated()) {
98
		?>
99
		<form name="login" action="<?php echo LOGIN_URL; ?>" method="post">
100
			
101
			<table cellpadding="0" cellspacing="0" border="0" width="150" align="center" style="margin-top: 10px;">
102
			<tr>
103
				<td class="border">
104
					<img src="<?php echo TEMPLATE_DIR; ?>/menu_top.gif" border="0" alt="" />
105
				</td>
106
			</tr>
107
			<tr>
108
				<td class="login" style="text-transform: uppercase;">
109
					<b><?php echo $TEXT['LOGIN']; ?></b>
110
				</td>
111
			</tr>
112
			<tr>
113
				<td class="login" style="text-align: left;">
114
					<?php echo $TEXT['USERNAME']; ?>:
115
				</td>
116
			</tr>
117
			<tr>
118
				<td class="login">
119
					<input type="text" name="username" />
120
				</td>
121
			</tr>
122
			<tr>
123
				<td class="login" style="text-align: left;">
124
					<?php echo $TEXT['PASSWORD']; ?>:
125
				</td>
126
			</tr>
127
			<tr>
128
				<td class="login">
129
					<input type="password" name="password" />
130
				</td>
131
			</tr>
132
			<tr>
133
				<td class="login">
134
					<input type="submit" name="submit" value="<?php echo $TEXT['LOGIN']; ?>" style="margin-top: 3px; text-transform: uppercase;" />
135
				</td>
136
			</tr>
137
			<tr>
138
				<td class="login">
139
					<a href="<?php echo FORGOT_URL; ?>"><?php echo $TEXT['FORGOT_DETAILS']; ?></a>
140
					<?php if(is_numeric(FRONTEND_SIGNUP)) { ?>
141
						<a href="<?php echo SIGNUP_URL; ?>"><?php echo $TEXT['SIGNUP']; ?></a>
142
					<?php } ?>
143
				</td>
144
			</tr>
145
			<tr>
146
				<td class="border">
147
					<img src="<?php echo TEMPLATE_DIR; ?>/menu_bottom.gif" border="0" alt="" />
148
				</td>
149
			</tr>
150
			</table>
151
		
152
		</form>
153
		<?php
154
		} elseif(FRONTEND_LOGIN AND $admin->is_authenticated()) {
155
		?>
156
		<form name="logout" action="<?php echo LOGOUT_URL; ?>" method="post">
157
			
158
			<table cellpadding="0" cellspacing="0" border="0" width="150" align="center" style="margin-top: 10px;">
159
			<tr>
160
				<td class="border">
161
					<img src="<?php echo TEMPLATE_DIR; ?>/menu_top.gif" border="0" alt="" />
162
				</td>
163
			</tr>
164
			<tr>
165
				<td class="login" style="text-transform: uppercase;">
166
					<b><?php echo $TEXT['LOGGED_IN']; ?></b>
167
				</td>
168
			</tr>
169
			<tr>
170
				<td class="login" style="padding-top: 15px; padding-bottom: 15px;">
171
					<?php echo $TEXT['WELCOME_BACK']; ?>, <?php echo $admin->get_display_name(); ?>
172
				</td>
173
			</tr>
174
			<tr>
175
				<td class="login">
176
					<input type="submit" name="submit" value="<?php echo $MENU['LOGOUT']; ?>" style="margin-top: 3px; text-transform: uppercase;" />
177
				</td>
178
			</tr>
179
			<tr>
180
				<td class="login">
181
					<a href="<?php echo PREFERENCES_URL; ?>"><?php echo $MENU['PREFERENCES']; ?></a>
182
				</td>
183
			</tr>
184
			<tr>
185
				<td class="border">
186
					<img src="<?php echo TEMPLATE_DIR; ?>/menu_bottom.gif" border="0" alt="" />
187
				</td>
188
			</tr>
189
			</table>
190
		
191
		</form>
192
		<?php
193
		}
194
		?>
195
	</td>
196
	<?php } ?>
197
	<td class="content" width="600" rowspan="2">
198
		<?php page_content(); ?>
199
	</td>
200
</tr>
201
<tr>
202
	<?php
203
	// Only show menu items if we are supposed to
204
	if(defined('SHOW_MENU') AND SHOW_MENU == true) {
205
	?>	
206
	<td height="20" width="155" valign="bottom" class="powered_by">
207
		<a href="http://www.websitebaker.org/" target="_blank">
208
			<img src="<?php echo TEMPLATE_DIR; ?>/powered.jpg" border="0" alt="Powered By Website Baker" />
209
		</a>
210
	</td>
211
	<?php } ?>
212
</tr>
213
<tr>
214
	<td colspan="2" class="border">
215
		<img src="<?php echo TEMPLATE_DIR; ?>/footer.png" border="0" alt="" />
216
	</td>
217
</tr>
218
<tr>
219
	<td colspan="2" class="footer">
220
		<?php page_footer(); ?>
221
	</td>
222
</tr>
223
</table>
224

    
225
</body>
226
</html>
(4-4/10)