Project

General

Profile

1
<?php
2
/**
3
 *
4
 * @category        frontend
5
 * @package         account
6
 * @author          WebsiteBaker Project
7
 * @copyright       2004-2009, Ryan Djurovich
8
 * @copyright       2009-2011, 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 5.2.2 and higher
13
 * @version         $Id: preferences.php 2 2017-07-02 15:14:29Z Manuela $
14
 * @filesource        $HeadURL: svn://isteam.dynxs.de/wb/2.10.x/trunk/account/preferences.php $
15
 * @lastmodified    $Date: 2017-07-02 17:14:29 +0200 (Sun, 02 Jul 2017) $
16
 *
17
 */
18

    
19
if (!defined( 'WB_PATH')){ require(dirname(__DIR__).'/config.php'); }
20
if (!class_exists('frontend')) {require(WB_PATH.'/framework/class.frontend.php');}
21

    
22
require_once(WB_PATH.'/framework/functions.php');
23

    
24
// Create new frontend object
25
if (!isset($wb) || !($wb instanceof frontend)) {
26
  $wb = new frontend();
27
}
28

    
29
if(!FRONTEND_LOGIN) {
30
    header('Location: '.WB_URL.'/index.php');
31
    exit(0);
32
}
33

    
34
if ($wb->is_authenticated()==false) {
35
    header('Location: '.WB_URL.'/account/login.php');
36
    exit(0);
37
}
38
$redirect_url = ((isset($_SESSION['HTTP_REFERER']) && $_SESSION['HTTP_REFERER'] != '') ? $_SESSION['HTTP_REFERER'] : WB_URL );
39
$redirect_url = ( isset($redirect) && ($redirect!='') ? $redirect : $redirect_url);
40
$page_id = @$_SESSION['PAGE_ID'] ?: PAGE_ID;
41
/*
42
$requestMethod = '_'.strtoupper($_SERVER['REQUEST_METHOD']);
43
$redirect  = strip_tags(isset(${$requestMethod}['redirect']) ? ${$requestMethod}['redirect'] : '');
44
$redirect = ((isset($_SERVER['HTTP_REFERER']) && empty($redirect)) ?  $_SERVER['HTTP_REFERER'] : $redirect);
45
$_SESSION['HTTP_REFERER'] = str_replace(WB_URL,'',$redirect);
46
*/
47

    
48
// Required page details
49
$page_description = '';
50
$page_keywords = '';
51
define('PAGE_ID', $page_id);
52
define('ROOT_PARENT', 0);
53
define('PARENT', 0);
54
define('LEVEL', 0);
55

    
56
define('PAGE_TITLE', $MENU['PREFERENCES']);
57
define('MENU_TITLE', $MENU['PREFERENCES']);
58
define('MODULE', '');
59
define('VISIBILITY', 'public');
60

    
61
define('PAGE_CONTENT', WB_PATH.'/account/preferences_form.php');
62
// Include the index (wrapper) file
63
$no_intro = true;
64
require(WB_PATH.'/index.php');
(10-10/15)