It has been a long time that we released a new recipe for vtiger.

Here is one.

[code language=”PHP”]

// Coloring datefields STP 24-Jul-2013

// Date of Today shows in GREEN

// Past in RED and future in BLACK

// Search for the following line in include/ListView/ListViewController.php

//  $value = $date->getDisplayDate();

// Approx line 314 in the file

// Replace the line with below code

$cdate = date(“Y-m-d”);

$vdate = $value;

if ($vdate == $cdate) $value = “<font color=green>”;

else if ($vdate < $cdate) $value = “<font color=red>”; else $value = “<font color=black>”;

$value .= $date->getDisplayDate().”</font>”; [/code]

Try it and do not forget to mail about your experience!!

Leave a Reply

Your email address will not be published. Required fields are marked *