New Feature: PLA icons and CSS can now be themeble

This commit is contained in:
Deon George
2009-07-08 16:14:50 +10:00
parent b4653e84a2
commit 7273ad292b
121 changed files with 96 additions and 88 deletions

View File

@@ -22,8 +22,6 @@ define('QUERYDIR',sprintf('%s/',realpath(LIBDIR.'../queries/')));
define('TMPLDIR',sprintf('%s/',realpath(LIBDIR.'../templates/')));
define('DOCDIR',sprintf('%s/',realpath(LIBDIR.'../doc/')));
define('HOOKSDIR',sprintf('%s/',realpath(LIBDIR.'../hooks/')));
define('CSSDIR','css/');
define('IMGDIR','images/');
define('JSDIR','js/');
/**
@@ -1616,9 +1614,9 @@ function get_icon($server_id,$dn,$object_classes=array()) {
$cval = explode('=',$tmp[0],2);
$cval = isset($cval[1]) ? $cval[1] : false;
if ($cval && false === strpos($cval,'..') &&
file_exists(realpath(sprintf('%s/countries/%s.png',IMGDIR,strtolower($cval)))))
file_exists(realpath(sprintf('%s/../countries/%s.png',IMGDIR,strtolower($cval)))))
return sprintf('countries/%s.png',strtolower($cval));
return sprintf('../countries/%s.png',strtolower($cval));
else
return 'country.png';