forked from mehulsbhatt/opensis
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathupgrade.inc.php
More file actions
33 lines (29 loc) · 784 Bytes
/
upgrade.inc.php
File metadata and controls
33 lines (29 loc) · 784 Bytes
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
<?php
if (file_exists("data.php"))
{
include("data.php");
}
if($DatabaseServer == '')
{
// redirect user to the install procedure
header('Location: install/index.php');
}
else {
// Server Names and Paths
db_start();
$sql = DBQuery("select value from APP where name='build'");
$build = mysql_fetch_assoc($sql);
$month = substr($build['value'],0,2);
$day = substr($build['value'],2,2);
$year = substr($build['value'],4,4);
$revision = substr($build['value'],8,3);
$build_date = mktime(0,0,0,$month,$day,$year);
if ($build_date < mktime(0,0,0,5,28,2009))
{
if($revision == '000') {
// redirect user to the upgrade procedure
header('Location: install/index.php?upreq=true');
}
}
}
?>