J
|
Jane 10/13/2006 |
Stephan, select `FieldName` from `TableName` where `DateField` is not NULL select `Fieldname` from `TableName` where `DateField`>now()+1
if ($value<now()-2) { $value = "<font color=red>".$value."</font>"; } |
M
|
mmponline author 10/18/2006 |
QUOTE if ($value<now()-2) { $value = "<font color=red>".$value."</font>"; }
|
J
|
Jane 10/19/2006 |
Stephan, global $conn; $rs = db_query("select datediff(now(), '". $value. "')",$conn); $data = db_fetch_numarray($rs); if ($data[0]>2) $value = "<font color=red>".$value."</font>"; |
M
|
mmponline author 10/19/2006 |
Jane |
J
|
Jane 10/19/2006 |
Stephan, |
M
|
mmponline author 10/23/2006 |
Jane if ($value<now()-2) { $value = "<font color=red>".$value."</font>"; }
|
![]() |
Alexey admin 10/23/2006 |
Stephan, // split $value to array $arr = db2time($value); // construct time $t = mktime[$arr[3],$arr[4],$arr[5],$arr[1],$arr[2],$arr[0]); // compare time with current time subtracted by 2 days if($t < time()-26060*24) $value = "<font color=red>".$value."</font>";
|
M
|
mmponline author 10/23/2006 |
I get a parse error using this code. |
![]() |
Alexey admin 11/1/2006 |
Stephan, $t = mktime($arr[3],$arr[4],$arr[5],$arr[1],$arr[2],$arr[0]); |
M
|
mmponline author 11/1/2006 |
Nope |
![]() |
Alexey admin 11/1/2006 |
Stephan, if($value) { // split $value to array $arr = db2time($value); // construct time $t = mktime($arr[3],$arr[4],$arr[5],$arr[1],$arr[2],$arr[0]); // compare time with current time subtracted by 2 days if($t < time()-26060*24) $value = "<font color=red>".$value."</font>"; } |