From: <sk...@us...> - 2008-10-27 14:22:31
|
Revision: 1448 http://dl-learner.svn.sourceforge.net/dl-learner/?rev=1448&view=rev Author: sknappe Date: 2008-10-27 14:22:25 +0000 (Mon, 27 Oct 2008) Log Message: ----------- bugfix Modified Paths: -------------- trunk/src/dbpedia-navigator/ajax_get_article.php trunk/src/dbpedia-navigator/helper_functions.php Modified: trunk/src/dbpedia-navigator/ajax_get_article.php =================================================================== --- trunk/src/dbpedia-navigator/ajax_get_article.php 2008-10-27 14:06:04 UTC (rev 1447) +++ trunk/src/dbpedia-navigator/ajax_get_article.php 2008-10-27 14:22:25 UTC (rev 1448) @@ -128,7 +128,7 @@ // display a list of classes if ($settings->classSystem=="YAGO") $content.='<br/><hr><h4>YAGO Classes</h4><br/>'; else if ($settings->classSystem=="DBpedia") $content.='<br/><hr><h4>DBpedia Classes</h4><br/>'; - $content .= '<p>'.formatClassArray($triples['http://www.w3.org/1999/02/22-rdf-syntax-ns#type'],$classSystem).'</p>'; + $content .= '<p>'.formatClassArray($triples['http://www.w3.org/1999/02/22-rdf-syntax-ns#type'],$settings->classSystem).'</p>'; } //skos-subjects Modified: trunk/src/dbpedia-navigator/helper_functions.php =================================================================== --- trunk/src/dbpedia-navigator/helper_functions.php 2008-10-27 14:06:04 UTC (rev 1447) +++ trunk/src/dbpedia-navigator/helper_functions.php 2008-10-27 14:22:25 UTC (rev 1448) @@ -399,7 +399,7 @@ for($i=0; $i<count($ar); $i++) { if ($classSystem=="YAGO") $prefix = 'http://dbpedia.org/class/yago/'; else if ($classSystem=="DBpedia") $prefix='http://dbpedia.org/ontology/'; - if(strpos($ar[$i]['value'],$prefix)!==0) continue; + if (substr($ar[$i]['value'],0,strlen($prefix))!=$prefix) continue; $query="SELECT label FROM categories WHERE category='".$ar[$i]['value']."' LIMIT 1"; $res=$databaseConnection->query($query); $result=$databaseConnection->nextEntry($res); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |