forked from eromba/taskstep
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathindex.php
40 lines (37 loc) · 1.11 KB
/
index.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
<?php include("includes/header.php") ?>
<div id="welcomebox">
<h2><img src="images/page.png" alt="" /> <?php echo $l_index_welcome; ?></h2>
<p>
<?php
$var = date("H");
if ($var <= 11) echo $l_index_introm;
else if ($var > 11 and $var < 18) echo $l_index_introa;
else echo $l_index_introe;
echo $l_index_introtext;
?>
<p><img src="images/chart_bar.png" alt="" />
<?php
$tasktotal = mysql_query("SELECT * FROM items WHERE done='0'");
$numtasks=mysql_num_rows($tasktotal);
if($numtasks == 1) echo $l_index_1task;
else echo $l_index_mtasks.$numtasks.$l_index_mtaske;
?>
</p>
</div>
<?php
display_frontpage();
//Tips Box
$result = mysql_query("SELECT * FROM settings WHERE setting='tips'");
while($r=mysql_fetch_array($result))
{
if($r['value'] == 1)
{
echo '<div id="tipsbox"><img src="images/information.png" alt="" /> ' . $l_index_tip . ': ';
//TEMPORARY LANGUAGE VALUE
srand((double)microtime()*1000000);
$arry_txt=preg_split("/--NEXT--/",join('',file("lang/tips_$language.txt")));
echo $arry_txt[rand(0,sizeof($arry_txt)-1)] . '</div>';
}
}
include('includes/footer.php');
?>