lib/sitemap.php contains the following line:
$ccms[breadcrumb] = "<span class=\"breadcrumb\">» <a href=\"/\" title=\"".ucfirst($cfg[sitename])." ".$cfg[homepage]."\">".ucfirst($cfg[homepage])."</a>";
If the system is installed under any directory other than root, this produces incorrect results.
To fix this in my system I have added a new variable to /lib/config.inc.php as follows:
//KM
// $cfg[root] must have trailing slash
$cfg[root] = "localhost/dev/compactcms/dev/";
Then the line in lib/sitemap.php gets updated to this:
$ccms["breadcrumb"] = '<span class="breadcrumb">» <a href="http://'.$cfg["root"].'" title="'.ucfirst($cfg["sitename"]).' '.$cfg["homepage"].'">'.ucfirst($cfg["homepage"]).'</a>';
I use $cfg["root"] in many places, including links to the css files.