Project

General

Profile

1
<?php
2

    
3
// $Id: index.php 691 2008-02-10 13:17:15Z doc $
4

    
5
/*
6

    
7
 Website Baker Project <http://www.websitebaker.org/>
8
 Copyright (C) 2004-2008, 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
if(!defined('WB_URL')) {
27
	header('Location: ../index.php');
28
	exit(0);
29
}
30

    
31
?>
32
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
33
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
34
<head>
35
<title><?php page_title(); ?></title>
36
<meta http-equiv="Content-Type" content="text/html; charset=<?php if(defined('DEFAULT_CHARSET')) { echo DEFAULT_CHARSET; } else { echo 'utf-8'; }?>" />
37
<meta name="description" content="<?php page_description(); ?>" />
38
<meta name="keywords" content="<?php page_keywords(); ?>" />
39
<link href="<?php echo TEMPLATE_DIR; ?>/screen.css" rel="stylesheet" type="text/css" media="screen" />
40
<link href="<?php echo TEMPLATE_DIR; ?>/print.css" rel="stylesheet" type="text/css" media="print" />
41
<?php
42
// this allows to include the optional module files (frontend.css, frontend.js) into the head section
43
if(function_exists('register_frontend_modfiles')) {
44
  register_frontend_modfiles('css');
45
  register_frontend_modfiles('js');
46
} ?>
47
<?php 
48
// this allows to add custom information to the head section of your template (WB-->Settings-->Website Header)
49
echo WEBSITE_HEADER; 
50
?>
51
</head>
52
<body>
53

    
54
<table cellpadding="0" cellspacing="0" border="0" align="center" class="main" width="750">
55
<tr>
56
	<td colspan="2" class="header" height="80">
57
		<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>
58
	</td>
59
</tr>
60
<tr>
61
	<?php
62
	// Only show menu items if we are supposed to
63
	if(SHOW_MENU) {
64
	?>	
65
	<td style="padding: 10px; background-color: #FFFFFF;" valign="top">
66
		<table cellpadding="0" cellspacing="0" border="0" width="150" align="center" class="menu">
67
		<tr>
68
			<td class="border">
69
				<img src="<?php echo TEMPLATE_DIR; ?>/menu_top.gif" border="0" alt="" />
70
			</td>
71
		</tr>
72
		<tr>
73
			<td width="170">
74
				<?php show_menu(); ?>
75
			</td>
76
		</tr>
77
		<tr>
78
			<td class="border">
79
				<img src="<?php echo TEMPLATE_DIR; ?>/menu_bottom.gif" border="0" alt="" />
80
			</td>
81
		</tr>
82
		</table>
83
		
84
		<?php if(SHOW_SEARCH) { ?>
85
		<form name="search" action="<?php echo WB_URL.'/search/index.php'; ?>" method="get">
86
			<table cellpadding="0" cellspacing="0" border="0" width="150" align="center" style="margin-top: 10px;">
87
				<tr>
88
					<td class="border">
89
						<img src="<?php echo TEMPLATE_DIR; ?>/menu_top.gif" border="0" alt="" />
90
					</td>
91
				</tr>
92
				<tr>
93
					<td class="login">
94
						<input type="text" name="string" />
95
					</td>
96
				</tr>
97
				<tr>
98
					<td class="login">
99
						<input type="submit" name="submit" value="<?php echo $TEXT['SEARCH']; ?>" />
100
					</td>
101
				</tr>
102
				<tr>
103
					<td class="border">
104
						<img src="<?php echo TEMPLATE_DIR; ?>/menu_bottom.gif" border="0" alt="" />
105
					</td>
106
				</tr>
107
			</table>
108
		</form>
109
		<?php } ?>
110
		
111
		<?php
112
		if(FRONTEND_LOGIN AND !$wb->is_authenticated()) {
113
		?>
114
		<form name="login" action="<?php echo LOGIN_URL; ?>" method="post">
115
			
116
			<table cellpadding="0" cellspacing="0" border="0" width="150" align="center" style="margin-top: 10px;">
117
			<tr>
118
				<td class="border">
119
					<img src="<?php echo TEMPLATE_DIR; ?>/menu_top.gif" border="0" alt="" />
120
				</td>
121
			</tr>
122
			<tr>
123
				<td class="login" style="text-transform: uppercase;">
124
					<b><?php echo $TEXT['LOGIN']; ?></b>
125
				</td>
126
			</tr>
127
			<tr>
128
				<td class="login" style="text-align: left;">
129
					<?php echo $TEXT['USERNAME']; ?>:
130
				</td>
131
			</tr>
132
			<tr>
133
				<td class="login">
134
					<input type="text" name="username" />
135
				</td>
136
			</tr>
137
			<tr>
138
				<td class="login" style="text-align: left;">
139
					<?php echo $TEXT['PASSWORD']; ?>:
140
				</td>
141
			</tr>
142
			<tr>
143
				<td class="login">
144
					<input type="password" name="password" />
145
				</td>
146
			</tr>
147
			<tr>
148
				<td class="login">
149
					<input type="submit" name="submit" value="<?php echo $TEXT['LOGIN']; ?>" style="margin-top: 3px; text-transform: uppercase;" />
150
				</td>
151
			</tr>
152
			<tr>
153
				<td class="login">
154
					<a href="<?php echo FORGOT_URL; ?>"><?php echo $TEXT['FORGOT_DETAILS']; ?></a>
155
					<?php if(is_numeric(FRONTEND_SIGNUP)) { ?>
156
						<a href="<?php echo SIGNUP_URL; ?>"><?php echo $TEXT['SIGNUP']; ?></a>
157
					<?php } ?>
158
				</td>
159
			</tr>
160
			<tr>
161
				<td class="border">
162
					<img src="<?php echo TEMPLATE_DIR; ?>/menu_bottom.gif" border="0" alt="" />
163
				</td>
164
			</tr>
165
			</table>
166
		
167
		</form>
168
		<?php
169
		} elseif(FRONTEND_LOGIN AND $wb->is_authenticated()) {
170
		?>
171
		<form name="logout" action="<?php echo LOGOUT_URL; ?>" method="post">
172
			
173
			<table cellpadding="0" cellspacing="0" border="0" width="150" align="center" style="margin-top: 10px;">
174
			<tr>
175
				<td class="border">
176
					<img src="<?php echo TEMPLATE_DIR; ?>/menu_top.gif" border="0" alt="" />
177
				</td>
178
			</tr>
179
			<tr>
180
				<td class="login" style="text-transform: uppercase;">
181
					<b><?php echo $TEXT['LOGGED_IN']; ?></b>
182
				</td>
183
			</tr>
184
			<tr>
185
				<td class="login" style="padding-top: 15px; padding-bottom: 15px;">
186
					<?php echo $TEXT['WELCOME_BACK']; ?>, <?php echo $wb->get_display_name(); ?>
187
				</td>
188
			</tr>
189
			<tr>
190
				<td class="login">
191
					<input type="submit" name="submit" value="<?php echo $MENU['LOGOUT']; ?>" style="margin-top: 3px; text-transform: uppercase;" />
192
				</td>
193
			</tr>
194
			<tr>
195
				<td class="login">
196
					<a href="<?php echo PREFERENCES_URL; ?>"><?php echo $MENU['PREFERENCES']; ?></a>
197
				</td>
198
			</tr>
199
			<tr>
200
				<td class="border">
201
					<img src="<?php echo TEMPLATE_DIR; ?>/menu_bottom.gif" border="0" alt="" />
202
				</td>
203
			</tr>
204
			</table>
205
		
206
		</form>
207
		<?php
208
		}
209
		?>
210
	</td>
211
	<?php } ?>
212
	<td class="content" width="600" rowspan="2">
213
		<?php page_content(); ?>
214
	</td>
215
</tr>
216
<tr>
217
	<?php
218
	// Only show menu items if we are supposed to
219
	if(defined('SHOW_MENU') AND SHOW_MENU == true) {
220
	?>	
221
	<td height="20" width="155" valign="bottom" class="powered_by">
222
		<a href="http://www.websitebaker.org/" target="_blank">
223
			<img src="<?php echo TEMPLATE_DIR; ?>/powered.jpg" border="0" alt="Powered By Website Baker" />
224
		</a>
225
	</td>
226
	<?php } ?>
227
</tr>
228
<tr>
229
	<td colspan="2" class="border">
230
		<img src="<?php echo TEMPLATE_DIR; ?>/footer.png" border="0" alt="" />
231
	</td>
232
</tr>
233
<tr>
234
	<td colspan="2" class="footer">
235
		<?php page_footer(); ?>
236
	</td>
237
</tr>
238
</table>
239

    
240
</body>
241
</html>
(4-4/10)