-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathfaq-page.php
144 lines (125 loc) · 4.41 KB
/
faq-page.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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
<?php
$tab = 0;
$hl_sub = -3;
include 'classes/classes.php';
session_start();
include 'vars/overview.php';
$holder = new Component();
$components = $holder->getByCommunity(0);
//error_reporting(E_ALL);
//ini_set("display_errors", 1);
$type = filter_var($_GET['type'], FILTER_SANITIZE_STRING);
$id = filter_var($_GET['id'], FILTER_SANITIZE_STRING);
$vars['editmode'] = filter_var($_GET['editmode'],FILTER_SANITIZE_STRING);
if($vars['editmode']){
if(!isset($_SESSION['user']) || $_SESSION['user']->role<1)
$vars['editmode'] = false;
}
$vars['errorID'] = filter_var($_GET['errorID'],FILTER_SANITIZE_NUMBER_INT);
if($vars['errorID']){
$errorID = new Error();
$errorID->getByID($vars['errorID']);
if(!$errorID->id){
$errorID = false;
}
}
if($id){
$data = new Component_Data();
$data->getByID($id);
$component = new Component();
$component->component = $data->component;
} elseif($type){
$holder = new Component_Data();
$component = new Component();
if($type=='questions'){
$results = $holder->getByComponent(104,0,0,20);
$theTitle = 'Questions';
$component->component = 104;
} elseif($type=='tutorials'){
$results = $holder->getByComponent(105,0,0,20);
$theTitle = 'Tutorials';
$component->component = 105;
}
}
?>
<!DOCTYPE html>
<!--[if IE 8]>
<html lang="en" class="ie8"> <![endif]-->
<!--[if IE 9]>
<html lang="en" class="ie9"> <![endif]-->
<!--[if !IE]><!-->
<html lang="en"> <!--<![endif]-->
<head>
<title>SciCrunch | FAQs</title>
<!-- Meta -->
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="description" content="">
<meta name="author" content="">
<!-- Favicon -->
<link rel="shortcut icon" href="/favicon.ico">
<!-- CSS Global Compulsory -->
<link rel="stylesheet" href="/assets/plugins/bootstrap/css/bootstrap.min.css">
<link rel="stylesheet" href="/assets/css/style.css">
<!-- CSS Implementing Plugins -->
<link rel="stylesheet" href="/assets/plugins/line-icons/line-icons.css">
<link rel="stylesheet" href="/assets/plugins/font-awesome/css/font-awesome.min.css">
<!-- CSS Page Style -->
<link rel="stylesheet" href="/assets/css/pages/page_faq1.css">
<!-- CSS Theme -->
<link rel="stylesheet" href="/assets/css/themes/default.css" id="style_color">
<link href="/assets/css/pages/blog_masonry_3col.css" rel="stylesheet">
<link rel="stylesheet" href="/assets/css/pages/page_log_reg_v2.css">
<link rel="stylesheet" href="/css/main.css">
<!-- CSS Customization -->
<link rel="stylesheet" href="/assets/css/custom.css">
</head>
<body>
<?php echo \helper\noscriptHTML(); ?>
<div class="wrapper">
<!--=== Header ===-->
<?php include 'ssi/header.php'; ?>
<!--=== End Header ===-->
<?php
if($id){
include 'faqs/single.php';
} elseif($type){
include 'faqs/list.php';
} else {
include 'faqs/home.php';
}
?>
<!--/container-->
<!--=== End FAQ Content ===-->
<?php include 'ssi/footer.php'; ?>
<!--=== End Copyright ===-->
</div>
<!--/End Wrapepr-->
<!-- JS Global Compulsory -->
<script type="text/javascript" src="/assets/plugins/jquery-1.10.2.min.js"></script>
<script type="text/javascript" src="/assets/plugins/jquery-migrate-1.2.1.min.js"></script>
<script type="text/javascript" src="/assets/plugins/bootstrap/js/bootstrap.min.js"></script>
<script type="text/javascript" src="/js/main.js"></script>
<!-- JS Implementing Plugins -->
<script type="text/javascript" src="/assets/plugins/back-to-top.js"></script>
<script type="text/javascript" src="/assets/plugins/jquery.parallax.js"></script>
<!-- JS Page Level -->
<script type="text/javascript" src="/assets/plugins/masonry/jquery.masonry.min.js"></script>
<!-- JS Page Level -->
<script type="text/javascript" src="/assets/js/app.js"></script>
<script type="text/javascript" src="/assets/js/pages/blog-masonry.js"></script>
<script type="text/javascript">
jQuery(document).ready(function () {
App.init();
App.initParallaxBg();
<?php if(isset($_SESSION['user'])){?>
setTimeout(updateLogin,<?php if($_SESSION['user']->last_check > time()) echo 1000*($_SESSION['user']->last_check-time()); else echo 1000 ?>);
<?php } ?>
});
</script>
<!--[if lt IE 9]>
<script src="/assets/plugins/respond.js"></script>
<script src="/assets/plugins/html5shiv.js"></script>
<![endif]-->
</body>
</html>