forked from osCommerce/oscommerce
/
account.php
42 lines (29 loc) · 1.15 KB
/
account.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
<?php
/*
$Id$
osCommerce, Open Source E-Commerce Solutions
http://www.oscommerce.com
Copyright (c) 2006 osCommerce
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License v2 (1991)
as published by the Free Software Foundation.
*/
$_SERVER['SCRIPT_FILENAME'] = __FILE__;
require('includes/application_top.php');
if ($osC_Customer->isLoggedOn() === false) {
if (!empty($_GET)) {
$first_array = array_slice($_GET, 0, 1);
}
if (empty($_GET) || (!empty($_GET) && !in_array(osc_sanitize_string(basename(key($first_array))), array('login', 'create', 'password_forgotten')))) {
$osC_NavigationHistory->setSnapshot();
osc_redirect(osc_href_link(FILENAME_ACCOUNT, 'login', 'SSL'));
}
}
$osC_Language->load('account');
if ($osC_Services->isStarted('breadcrumb')) {
$osC_Breadcrumb->add($osC_Language->get('breadcrumb_my_account'), osc_href_link(FILENAME_ACCOUNT, null, 'SSL'));
}
$osC_Template = osC_Template::setup('account');
require('templates/' . $osC_Template->getCode() . '.php');
require('includes/application_bottom.php');
?>