if ereg en index _SERVER REQUEST_URI left strtotime November 15 2009 2

 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
if (ereg("/en/index",$_SERVER['REQUEST_URI'])) {
$left = (strtotime("November 15, 2009 23:59:59") - time());
$time_left = array(
'd'=>floor($left/(3600*24)),
'h'=>floor(23.99 - date('G')),
'm'=>floor(59 - date(i)),
'p'=>floor(23.99 - date('G'))
);
$smarty->assign('time_left',$time_left);
ob_start();
include(dirname(__FILE__)."/forms/form_submit.php");
$form = ob_get_contents();
ob_clean();
$smarty->assign('form', $form);
$smarty->display('index.html');
}
//Contact Us
else if (ereg("/en/skill_test",$_SERVER['REQUEST_URI'])) {
ob_start();
include(dirname(__FILE__)."/forms/form_skill.php");
$form = ob_get_contents();
ob_clean();
$smarty->assign('form', $form);
$smarty->display('rules.html');
}
else {
$smarty->display('rules.html');