From: <sk...@us...> - 2008-02-07 10:40:29
|
Revision: 510 http://dl-learner.svn.sourceforge.net/dl-learner/?rev=510&view=rev Author: sknappe Date: 2008-02-07 02:40:10 -0800 (Thu, 07 Feb 2008) Log Message: ----------- Redirects are now properly handled Modified Paths: -------------- trunk/src/dbpedia-navigator/DLLearnerConnection.php Modified: trunk/src/dbpedia-navigator/DLLearnerConnection.php =================================================================== --- trunk/src/dbpedia-navigator/DLLearnerConnection.php 2008-02-07 09:55:12 UTC (rev 509) +++ trunk/src/dbpedia-navigator/DLLearnerConnection.php 2008-02-07 10:40:10 UTC (rev 510) @@ -104,7 +104,7 @@ function getTriples($label) { $query="SELECT ?pred ?obj ". - "WHERE {<http://dbpedia.org/resource/".str_replace(' ','_',$label)."> ?pred ?obj}"; + "WHERE {{<http://dbpedia.org/resource/".str_replace(' ','_',$label)."> ?pred ?obj}UNION{<http://dbpedia.org/resource/".str_replace(' ','_',$label)."> <http://dbpedia.org/property/redirect> ?Conc.?Conc ?pred ?obj}}"; $result=$this->getSparqlResult($query); if (!isset($result->item)) throw new Exception("Your query brought no result. The Label-Search is started."); $ret=array(); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |