Nicely colour toner names on Kyocera printers

git-svn-id: http://www.observium.org/svn/observer/trunk@1424 61d68cd4-352d-0410-923a-c4978735b2b8
This commit is contained in:
Tom Laermans
2010-07-18 20:36:23 +00:00
parent 9ba384e317
commit 8fe7ced23c

View File

@@ -36,10 +36,10 @@ while($toner = mysql_fetch_array($sql))
unset($iter);
break;
}
if (stripos($toner['toner_descr'],"cyan" ) !== false) { $colour = "55D6D3"; }
if (stripos($toner['toner_descr'],"magenta") !== false) { $colour = "F24AC8"; }
if (stripos($toner['toner_descr'],"yellow" ) !== false) { $colour = "FFF200"; }
if (stripos($toner['toner_descr'],"black" ) !== false) { $colour = "000000"; }
if (stripos($toner['toner_descr'],"cyan" ) !== false || substr($toner['toner_descr'],-1) == 'C') { $colour = "55D6D3"; }
if (stripos($toner['toner_descr'],"magenta") !== false || substr($toner['toner_descr'],-1) == 'M') { $colour = "F24AC8"; }
if (stripos($toner['toner_descr'],"yellow" ) !== false || substr($toner['toner_descr'],-1) == 'Y') { $colour = "FFF200"; }
if (stripos($toner['toner_descr'],"black" ) !== false || substr($toner['toner_descr'],-1) == 'K') { $colour = "000000"; }
$hostname = gethostbyid($toner['device_id']);