-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathindex.php
More file actions
298 lines (116 loc) · 4.23 KB
/
index.php
File metadata and controls
298 lines (116 loc) · 4.23 KB
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
145
146
147
148
149
<?php
error_reporting(E_ALL & ~E_WARNING & ~E_NOTICE);
/*
ini_set('display_errors', 1);
ini_set('display_startup_errors', 1);
error_reporting(E_ALL);
*/
session_start();
include("templates/script.tpl");
header('Content-Type: text/html; charset=UTF-8');
if(!isset($_GET['s'])) {
$_GET['s']=0;
}
if(isset($_GET['lang']) && in_array($_GET['lang'], array('ar','en'))){
$_SESSION['ilang'] = $_GET['lang'];
//header('Location: ')
}
include("../application/Lang/".($_SESSION['ilang'] ? $_SESSION['ilang'] : 'en')."/Lang.php");
?>
<!DOCTYPE html>
<html>
<head>
<title>Install script</title>
<link rel="shortcut icon" href="../favicon.ico"/>
<link href="../gpack/lang/en/compact.css" rel="stylesheet" type="text/css" />
<script src="http://www.cy-pr.com/tools/time/time.js" type="text/javascript"></script>
</head>
<style>h1 {
font-family: monotype corsiva, Helvetica, sans-serif;
color:#a40020;
font-size: 40px;
}</style>
<body class="v35 webkit login ar-AE login perspectiveBuildings <?php echo DIRECTION; ?> season- buildingsV3">
<div id="background">
<div id="headerBar"></div>
<div id="bodyWrapper">
<div id="header">
<?php
if(isset($_GET['lang'])){
if(count($_GET)==1){
$_SERVER['QUERY_STRING']= preg_replace('/lang='.$_GET['lang'].'/','',$_SERVER['QUERY_STRING']);
}else{
$_SERVER['QUERY_STRING']= preg_replace('/&lang='.$_GET['lang'].'/','',$_SERVER['QUERY_STRING']);
}
}
if(count($_GET) && isset($_GET['lang'])){
if($_GET['lang']!='en'){
$linken='?'.$_SERVER['QUERY_STRING'].'&lang=en';
}else{$linken='?'.$_SERVER['QUERY_STRING'];}
if($_GET['lang']!='ru'){
$linkru='?'.$_SERVER['QUERY_STRING'].'&lang=ru';
}else{$linkru='?'.$_SERVER['QUERY_STRING'];}
}elseif(!count($_GET)){
$linkru='?lang=ru';
$linken='?lang=en';
}else{
$linkru='?'.$_SERVER['QUERY_STRING'].'&lang=ru';
$linken='?'.$_SERVER['QUERY_STRING'].'&lang=en';
}
?>
</div>
<div id="center" style="float:none">
<center>
<div class="headline">
<span class="f18 c5" ><h1>Install script</h1></span></div>
<br />
<div id="contentOuterContainer" style="float:none;padding:10rem;padding-top:0" >
<div class="contentTitle">
</div>
<div class="contentContainer" style="padding:50px;padding-top:0">
<br />
<?php
IHG_Progressbar::draw_css();
$bar = new IHG_Progressbar(7, 'step %d From %d ');
$bar->draw();
for($i = 0; $i < ($_GET['s']+1); $i++) {
$bar->tick();
}
?>
<?php
if(substr(sprintf('%o', fileperms('../')), -4)<'700'){
echo"<span class='f18 c5'>ERROR!</span><br />It's not possible to write the config file. Change the permission to '777'. After that, refresh this page!";
} else
switch($_GET['s']){
case 0:
include("templates/greet.tpl");break;
case 1:
include("templates/config.tpl");
break;
case 2:
include("templates/dataform.tpl");
break;
case 3:
include("templates/field.tpl");
break;
case 4:
include("templates/multihunter.tpl");
break;
case 5:
include("templates/oasis.tpl");
break;
case 6:
include("templates/end.tpl");
break;
}
?>
</div>
<div class="clear"> </div>
<div class="contentFooter"></div>
</center>
<div class="clear"></div>
</div>
</div>
<div id="ce"></div>
</body>
</html>