Project

General

Profile

« Previous | Next » 

Revision 1289

Added by kweitzel almost 15 years ago

Branch 2.8.1 merged back into Trunk

View differences:

index.php
1
<?php
2

  
3
// $Id$
4

  
5
/*
6

  
7
 Website Baker Project <http://www.websitebaker.org/>
8
 Copyright (C) 2004-2009, 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
// Include the config file
27
require('../config.php');
28

  
29
// Required page details
30
$page_id = 0;
31
$page_description = '';
32
$page_keywords = '';
33
define('PAGE_ID', 0);
34
define('ROOT_PARENT', 0);
35
define('PARENT', 0);
36
define('LEVEL', 0);
37
define('PAGE_TITLE', $TEXT['SEARCH']);
38
define('MENU_TITLE', $TEXT['SEARCH']);
39
define('MODULE', '');
40
define('VISIBILITY', 'public');
41
define('PAGE_CONTENT', 'search.php');
42

  
43
// Find out what the search template is
44
$database = new database();
45
$query_template = $database->query("SELECT value FROM ".TABLE_PREFIX."search WHERE name = 'template' LIMIT 1");
46
$fetch_template = $query_template->fetchRow();
47
$template = $fetch_template['value'];
48
if($template != '') {
49
	define('TEMPLATE', $template);
50
}
51
unset($template);
52

  
53
//Get the referrer page ID if it exists
54
if(isset($_REQUEST['referrer']) && is_numeric($_REQUEST['referrer']) && intval($_REQUEST['referrer']) > 0) {
55
	define('REFERRER_ID', intval($_REQUEST['referrer']));
56
} else {
57
	define('REFERRER_ID', 0);
58
}
59

  
60
// Include index (wrapper) file
61
require(WB_PATH.'/index.php');
62

  
1
<?php
2
/**
3
 *
4
 * @category        frontend
5
 * @package         search
6
 * @author          WebsiteBaker Project
7
 * @copyright       2004-2009, Ryan Djurovich
8
 * @copyright       2009-2010, Website Baker Org. e.V.
9
 * @link			http://www.websitebaker2.org/
10
 * @license         http://www.gnu.org/licenses/gpl.html
11
 * @platform        WebsiteBaker 2.8.x
12
 * @requirements    PHP 4.3.4 and higher
13
 * @version         $Id$
14
 * @filesource		$HeadURL$
15
 * @lastmodified    $Date$
16
 *
17
 */
18

  
19
// Include the config file
20
require('../config.php');
21

  
22
// Required page details
23
$page_id = 0;
24
$page_description = '';
25
$page_keywords = '';
26
define('PAGE_ID', 0);
27
define('ROOT_PARENT', 0);
28
define('PARENT', 0);
29
define('LEVEL', 0);
30
define('PAGE_TITLE', $TEXT['SEARCH']);
31
define('MENU_TITLE', $TEXT['SEARCH']);
32
define('MODULE', '');
33
define('VISIBILITY', 'public');
34
define('PAGE_CONTENT', 'search.php');
35

  
36
// Find out what the search template is
37
$database = new database();
38
$query_template = $database->query("SELECT value FROM ".TABLE_PREFIX."search WHERE name = 'template' LIMIT 1");
39
$fetch_template = $query_template->fetchRow();
40
$template = $fetch_template['value'];
41
if($template != '') {
42
	define('TEMPLATE', $template);
43
}
44
unset($template);
45

  
46
//Get the referrer page ID if it exists
47
if(isset($_REQUEST['referrer']) && is_numeric($_REQUEST['referrer']) && intval($_REQUEST['referrer']) > 0) {
48
	define('REFERRER_ID', intval($_REQUEST['referrer']));
49
} else {
50
	define('REFERRER_ID', 0);
51
}
52

  
53
// Include index (wrapper) file
54
require(WB_PATH.'/index.php');
55

  
63 56
?>
64 57

  

Also available in: Unified diff